package android.content.pm;

import android.content.ComponentName;
import android.content.IntentFilter;
import android.content.IntentFilter.MalformedMimeTypeException;
import android.content.res.AssetManager;
import android.content.res.Resources;
import android.content.res.TypedArray;
import android.content.res.XmlResourceParser;
import android.os.Build.VERSION;
import android.os.Bundle;
import android.os.PatternMatcher;
import android.util.AttributeSet;
import android.util.DisplayMetrics;
import android.util.Log;
import android.util.TypedValue;
import com.android.internal.R.styleable;
import com.android.internal.util.XmlUtils;
import java.io.BufferedInputStream;
import java.io.File;
import java.io.IOException;
import java.io.InputStream;
import java.lang.ref.WeakReference;
import java.security.cert.Certificate;
import java.util.ArrayList;
import java.util.jar.JarEntry;
import java.util.jar.JarFile;
import org.xmlpull.v1.XmlPullParser;
import org.xmlpull.v1.XmlPullParserException;

public class PackageParser
{
  private static final String ANDROID_RESOURCES = "http://schemas.android.com/apk/res/android";
  public static final NewPermissionInfo[] NEW_PERMISSIONS;
  public static final int PARSE_CHATTY = 2;
  private static final int PARSE_DEFAULT_INSTALL_LOCATION = -1;
  public static final int PARSE_FORWARD_LOCK = 16;
  public static final int PARSE_IGNORE_PROCESSES = 8;
  public static final int PARSE_IS_SYSTEM = 1;
  public static final int PARSE_IS_SYSTEM_DIR = 64;
  public static final int PARSE_MUST_BE_APK = 4;
  public static final int PARSE_ON_SDCARD = 32;
  private static final boolean RIGID_PARSER = 0;
  private static final String SDK_CODENAME;
  private static final int SDK_VERSION = 0;
  private static final String TAG = "PackageParser";
  private static WeakReference<byte[]> mReadBuffer;
  private static final Object mSync;
  private static boolean sCompatibilityModeEnabled;
  private String mArchiveSourcePath;
  private ParseComponentArgs mParseActivityAliasArgs;
  private ParseComponentArgs mParseActivityArgs;
  private int mParseError = 1;
  private ParsePackageItemArgs mParseInstrumentationArgs;
  private ParseComponentArgs mParseProviderArgs;
  private ParseComponentArgs mParseServiceArgs;
  private String[] mSeparateProcesses;

  static
  {
    NewPermissionInfo[] arrayOfNewPermissionInfo = new NewPermissionInfo[2];
    arrayOfNewPermissionInfo[0] = new NewPermissionInfo("android.permission.WRITE_EXTERNAL_STORAGE", 4, 0);
    arrayOfNewPermissionInfo[1] = new NewPermissionInfo("android.permission.READ_PHONE_STATE", 4, 0);
    NEW_PERMISSIONS = arrayOfNewPermissionInfo;
    SDK_VERSION = Build.VERSION.SDK_INT;
    if ("REL".equals(Build.VERSION.CODENAME));
    for (String str = null; ; str = Build.VERSION.CODENAME)
    {
      SDK_CODENAME = str;
      mSync = new Object();
      sCompatibilityModeEnabled = true;
      return;
    }
  }

  public PackageParser(String paramString)
  {
    this.mArchiveSourcePath = paramString;
  }

  private static String buildClassName(String paramString, CharSequence paramCharSequence, String[] paramArrayOfString)
  {
    if ((paramCharSequence == null) || (paramCharSequence.length() <= 0))
    {
      paramArrayOfString[0] = "Empty class name in package " + paramString;
      return null;
    }
    String str = paramCharSequence.toString();
    int i = str.charAt(0);
    if (i == 46)
      return paramString + str.intern();
    if (str.indexOf(46) < 0)
    {
      StringBuilder localStringBuilder = new StringBuilder(paramString);
      localStringBuilder.append('.');
      localStringBuilder.append(str);
      return localStringBuilder.toString().intern();
    }
    if ((i >= 97) && (i <= 122))
      return str.intern();
    paramArrayOfString[0] = "Bad class name " + str + " in package " + paramString;
    return null;
  }

  private static String buildCompoundName(String paramString1, CharSequence paramCharSequence, String paramString2, String[] paramArrayOfString)
  {
    String str1 = paramCharSequence.toString();
    int i = str1.charAt(0);
    if ((paramString1 != null) && (i == 58))
    {
      if (str1.length() < 2)
      {
        paramArrayOfString[0] = "Bad " + paramString2 + " name " + str1 + " in package " + paramString1 + ": must be at least two characters";
        return null;
      }
      String str3 = validateName(str1.substring(1), false);
      if (str3 != null)
      {
        paramArrayOfString[0] = "Invalid " + paramString2 + " name " + str1 + " in package " + paramString1 + ": " + str3;
        return null;
      }
      return paramString1 + str1.intern();
    }
    String str2 = validateName(str1, true);
    if ((str2 != null) && (!("system".equals(str1))))
    {
      paramArrayOfString[0] = "Invalid " + paramString2 + " name " + str1 + " in package " + paramString1 + ": " + str2;
      return null;
    }
    return str1.intern();
  }

  private static String buildProcessName(String paramString1, String paramString2, CharSequence paramCharSequence, int paramInt, String[] paramArrayOfString1, String[] paramArrayOfString2)
  {
    if (((paramInt & 0x8) != 0) && (!("system".equals(paramCharSequence))))
      if (paramString2 == null);
    do
    {
      return paramString2;
      return paramString1;
      if (paramArrayOfString1 == null)
        continue;
      for (int i = -1 + paramArrayOfString1.length; i >= 0; --i)
      {
        String str = paramArrayOfString1[i];
        if ((str.equals(paramString1)) || (str.equals(paramString2)) || (str.equals(paramCharSequence)))
          return paramString1;
      }
    }
    while ((paramCharSequence == null) || (paramCharSequence.length() <= 0));
    return buildCompoundName(paramString1, paramCharSequence, "process", paramArrayOfString2);
  }

  private static String buildTaskAffinityName(String paramString1, String paramString2, CharSequence paramCharSequence, String[] paramArrayOfString)
  {
    if (paramCharSequence == null)
      return paramString2;
    if (paramCharSequence.length() <= 0)
      return null;
    return buildCompoundName(paramString1, paramCharSequence, "taskAffinity", paramArrayOfString);
  }

  private static boolean copyNeeded(int paramInt, Package paramPackage, Bundle paramBundle)
  {
    int i;
    if (paramPackage.mSetEnabled != 0)
      if (paramPackage.mSetEnabled == 1)
      {
        i = 1;
        label17: if (paramPackage.applicationInfo.enabled == i)
          break label35;
      }
    do
    {
      return true;
      i = 0;
      label35: break label17:
    }
    while ((((paramInt & 0x80) != 0) && (((paramBundle != null) || (paramPackage.mAppMetaData != null)))) || (((paramInt & 0x400) != 0) && (paramPackage.usesLibraryFiles != null)));
    return false;
  }

  public static final ActivityInfo generateActivityInfo(Activity paramActivity, int paramInt)
  {
    if (paramActivity == null)
      return null;
    if (!(copyNeeded(paramInt, paramActivity.owner, paramActivity.metaData)))
      return paramActivity.info;
    ActivityInfo localActivityInfo = new ActivityInfo(paramActivity.info);
    localActivityInfo.metaData = paramActivity.metaData;
    localActivityInfo.applicationInfo = generateApplicationInfo(paramActivity.owner, paramInt);
    return localActivityInfo;
  }

  public static ApplicationInfo generateApplicationInfo(Package paramPackage, int paramInt)
  {
    ApplicationInfo localApplicationInfo = null;
    if (paramPackage == null);
    do
    {
      return localApplicationInfo;
      if (!(copyNeeded(paramInt, paramPackage, null)))
      {
        if (!(sCompatibilityModeEnabled))
          paramPackage.applicationInfo.disableCompatibilityMode();
        return paramPackage.applicationInfo;
      }
      localApplicationInfo = new ApplicationInfo(paramPackage.applicationInfo);
      if ((paramInt & 0x80) != 0)
        localApplicationInfo.metaData = paramPackage.mAppMetaData;
      if ((paramInt & 0x400) != 0)
        localApplicationInfo.sharedLibraryFiles = paramPackage.usesLibraryFiles;
      if (!(sCompatibilityModeEnabled))
        localApplicationInfo.disableCompatibilityMode();
      if (paramPackage.mSetEnabled != 1)
        continue;
      localApplicationInfo.enabled = true;
      return localApplicationInfo;
    }
    while (paramPackage.mSetEnabled != 2);
    localApplicationInfo.enabled = false;
    return localApplicationInfo;
  }

  public static final InstrumentationInfo generateInstrumentationInfo(Instrumentation paramInstrumentation, int paramInt)
  {
    if (paramInstrumentation == null)
      return null;
    if ((paramInt & 0x80) == 0)
      return paramInstrumentation.info;
    InstrumentationInfo localInstrumentationInfo = new InstrumentationInfo(paramInstrumentation.info);
    localInstrumentationInfo.metaData = paramInstrumentation.metaData;
    return localInstrumentationInfo;
  }

  public static PackageInfo generatePackageInfo(Package paramPackage, int[] paramArrayOfInt, int paramInt, long paramLong1, long paramLong2)
  {
    label161: int i22;
    int i25;
    int i26;
    int i27;
    int i29;
    PackageInfo localPackageInfo = new PackageInfo();
    localPackageInfo.packageName = paramPackage.packageName;
    localPackageInfo.versionCode = paramPackage.mVersionCode;
    localPackageInfo.versionName = paramPackage.mVersionName;
    localPackageInfo.sharedUserId = paramPackage.mSharedUserId;
    localPackageInfo.sharedUserLabel = paramPackage.mSharedUserLabel;
    localPackageInfo.applicationInfo = generateApplicationInfo(paramPackage, paramInt);
    localPackageInfo.installLocation = paramPackage.installLocation;
    localPackageInfo.firstInstallTime = paramLong1;
    localPackageInfo.lastUpdateTime = paramLong2;
    if ((paramInt & 0x100) != 0)
      localPackageInfo.gids = paramArrayOfInt;
    if ((paramInt & 0x4000) != 0)
    {
      int i28 = paramPackage.configPreferences.size();
      if (i28 > 0)
      {
        localPackageInfo.configPreferences = new ConfigurationInfo[i28];
        paramPackage.configPreferences.toArray(localPackageInfo.configPreferences);
      }
      if (paramPackage.reqFeatures == null)
        break label313;
      i29 = paramPackage.reqFeatures.size();
      if (i29 > 0)
      {
        localPackageInfo.reqFeatures = new FeatureInfo[i29];
        paramPackage.reqFeatures.toArray(localPackageInfo.reqFeatures);
      }
    }
    if ((paramInt & 0x1) != 0)
    {
      i22 = paramPackage.activities.size();
      if (i22 > 0)
        if ((paramInt & 0x200) != 0)
        {
          localPackageInfo.activities = new ActivityInfo[i22];
          label227: i25 = 0;
          i26 = 0;
          label233: if (i25 >= i22)
            break label375;
          if ((!(((Activity)paramPackage.activities.get(i25)).info.enabled)) && ((paramInt & 0x200) == 0))
            break label1201;
          ActivityInfo[] arrayOfActivityInfo2 = localPackageInfo.activities;
          i27 = i26 + 1;
          arrayOfActivityInfo2[i26] = generateActivityInfo((Activity)paramPackage.activities.get(i25), paramInt);
        }
    }
    while (true)
    {
      label313: label375: int i16;
      int i19;
      int i20;
      int i21;
      ++i25;
      i26 = i27;
      break label233:
      i29 = 0;
      break label161:
      int i23 = 0;
      for (int i24 = 0; i24 < i22; ++i24)
      {
        if (!(((Activity)paramPackage.activities.get(i24)).info.enabled))
          continue;
        ++i23;
      }
      localPackageInfo.activities = new ActivityInfo[i23];
      break label227:
      if ((paramInt & 0x2) != 0)
      {
        i16 = paramPackage.receivers.size();
        if (i16 > 0)
          if ((paramInt & 0x200) != 0)
          {
            localPackageInfo.receivers = new ActivityInfo[i16];
            label413: i19 = 0;
            i20 = 0;
            label419: if (i19 >= i16)
              break label555;
            if ((!(((Activity)paramPackage.receivers.get(i19)).info.enabled)) && ((paramInt & 0x200) == 0))
              break label1194;
            ActivityInfo[] arrayOfActivityInfo1 = localPackageInfo.receivers;
            i21 = i20 + 1;
            arrayOfActivityInfo1[i20] = generateActivityInfo((Activity)paramPackage.receivers.get(i19), paramInt);
          }
      }
      while (true)
      {
        label555: int i10;
        int i13;
        int i14;
        int i15;
        ++i19;
        i20 = i21;
        break label419:
        int i17 = 0;
        for (int i18 = 0; i18 < i16; ++i18)
        {
          if (!(((Activity)paramPackage.receivers.get(i18)).info.enabled))
            continue;
          ++i17;
        }
        localPackageInfo.receivers = new ActivityInfo[i17];
        break label413:
        if ((paramInt & 0x4) != 0)
        {
          i10 = paramPackage.services.size();
          if (i10 > 0)
            if ((paramInt & 0x200) != 0)
            {
              localPackageInfo.services = new ServiceInfo[i10];
              label593: i13 = 0;
              i14 = 0;
              label599: if (i13 >= i10)
                break label735;
              if ((!(((Service)paramPackage.services.get(i13)).info.enabled)) && ((paramInt & 0x200) == 0))
                break label1187;
              ServiceInfo[] arrayOfServiceInfo = localPackageInfo.services;
              i15 = i14 + 1;
              arrayOfServiceInfo[i14] = generateServiceInfo((Service)paramPackage.services.get(i13), paramInt);
            }
        }
        while (true)
        {
          label735: int i4;
          int i7;
          int i8;
          int i9;
          ++i13;
          i14 = i15;
          break label599:
          int i11 = 0;
          for (int i12 = 0; i12 < i10; ++i12)
          {
            if (!(((Service)paramPackage.services.get(i12)).info.enabled))
              continue;
            ++i11;
          }
          localPackageInfo.services = new ServiceInfo[i11];
          break label593:
          if ((paramInt & 0x8) != 0)
          {
            i4 = paramPackage.providers.size();
            if (i4 > 0)
              if ((paramInt & 0x200) != 0)
              {
                localPackageInfo.providers = new ProviderInfo[i4];
                label774: i7 = 0;
                i8 = 0;
                label780: if (i7 >= i4)
                  break label916;
                if ((!(((Provider)paramPackage.providers.get(i7)).info.enabled)) && ((paramInt & 0x200) == 0))
                  break label1180;
                ProviderInfo[] arrayOfProviderInfo = localPackageInfo.providers;
                i9 = i8 + 1;
                arrayOfProviderInfo[i8] = generateProviderInfo((Provider)paramPackage.providers.get(i7), paramInt);
              }
          }
          while (true)
          {
            ++i7;
            i8 = i9;
            break label780:
            int i5 = 0;
            for (int i6 = 0; i6 < i4; ++i6)
            {
              if (!(((Provider)paramPackage.providers.get(i6)).info.enabled))
                continue;
              ++i5;
            }
            localPackageInfo.providers = new ProviderInfo[i5];
            break label774:
            if ((paramInt & 0x10) != 0)
            {
              label916: int i2 = paramPackage.instrumentation.size();
              if (i2 > 0)
              {
                localPackageInfo.instrumentation = new InstrumentationInfo[i2];
                for (int i3 = 0; i3 < i2; ++i3)
                  localPackageInfo.instrumentation[i3] = generateInstrumentationInfo((Instrumentation)paramPackage.instrumentation.get(i3), paramInt);
              }
            }
            if ((paramInt & 0x1000) != 0)
            {
              int j = paramPackage.permissions.size();
              if (j > 0)
              {
                localPackageInfo.permissions = new PermissionInfo[j];
                for (int i1 = 0; i1 < j; ++i1)
                  localPackageInfo.permissions[i1] = generatePermissionInfo((Permission)paramPackage.permissions.get(i1), paramInt);
              }
              int k = paramPackage.requestedPermissions.size();
              if (k > 0)
              {
                localPackageInfo.requestedPermissions = new String[k];
                for (int l = 0; l < k; ++l)
                  localPackageInfo.requestedPermissions[l] = ((String)paramPackage.requestedPermissions.get(l));
              }
            }
            if ((paramInt & 0x40) != 0)
              if (paramPackage.mSignatures == null)
                break label1174;
            for (int i = paramPackage.mSignatures.length; ; i = 0)
            {
              if (i > 0)
              {
                localPackageInfo.signatures = new Signature[i];
                System.arraycopy(paramPackage.mSignatures, 0, localPackageInfo.signatures, 0, i);
              }
              label1174: return localPackageInfo;
            }
            label1180: i9 = i8;
          }
          label1187: i15 = i14;
        }
        label1194: i21 = i20;
      }
      label1201: i27 = i26;
    }
  }

  public static final PermissionGroupInfo generatePermissionGroupInfo(PermissionGroup paramPermissionGroup, int paramInt)
  {
    if (paramPermissionGroup == null)
      return null;
    if ((paramInt & 0x80) == 0)
      return paramPermissionGroup.info;
    PermissionGroupInfo localPermissionGroupInfo = new PermissionGroupInfo(paramPermissionGroup.info);
    localPermissionGroupInfo.metaData = paramPermissionGroup.metaData;
    return localPermissionGroupInfo;
  }

  public static final PermissionInfo generatePermissionInfo(Permission paramPermission, int paramInt)
  {
    if (paramPermission == null)
      return null;
    if ((paramInt & 0x80) == 0)
      return paramPermission.info;
    PermissionInfo localPermissionInfo = new PermissionInfo(paramPermission.info);
    localPermissionInfo.metaData = paramPermission.metaData;
    return localPermissionInfo;
  }

  public static final ProviderInfo generateProviderInfo(Provider paramProvider, int paramInt)
  {
    if (paramProvider == null)
      return null;
    if ((!(copyNeeded(paramInt, paramProvider.owner, paramProvider.metaData))) && ((((paramInt & 0x800) != 0) || (paramProvider.info.uriPermissionPatterns == null))))
      return paramProvider.info;
    ProviderInfo localProviderInfo = new ProviderInfo(paramProvider.info);
    localProviderInfo.metaData = paramProvider.metaData;
    if ((paramInt & 0x800) == 0)
      localProviderInfo.uriPermissionPatterns = null;
    localProviderInfo.applicationInfo = generateApplicationInfo(paramProvider.owner, paramInt);
    return localProviderInfo;
  }

  public static final ServiceInfo generateServiceInfo(Service paramService, int paramInt)
  {
    if (paramService == null)
      return null;
    if (!(copyNeeded(paramInt, paramService.owner, paramService.metaData)))
      return paramService.info;
    ServiceInfo localServiceInfo = new ServiceInfo(paramService.info);
    localServiceInfo.metaData = paramService.metaData;
    localServiceInfo.applicationInfo = generateApplicationInfo(paramService.owner, paramInt);
    return localServiceInfo;
  }

  private static final boolean isPackageFilename(String paramString)
  {
    return paramString.endsWith(".apk");
  }

  private Certificate[] loadCertificates(JarFile paramJarFile, JarEntry paramJarEntry, byte[] paramArrayOfByte)
  {
    try
    {
      BufferedInputStream localBufferedInputStream = new BufferedInputStream(paramJarFile.getInputStream(paramJarEntry));
      while (localBufferedInputStream.read(paramArrayOfByte, 0, paramArrayOfByte.length) != -1);
      localBufferedInputStream.close();
      Object localObject = null;
      if (paramJarEntry != null)
      {
        Certificate[] arrayOfCertificate = paramJarEntry.getCertificates();
        localObject = arrayOfCertificate;
      }
      return localObject;
    }
    catch (IOException localIOException)
    {
      Log.w("PackageParser", "Exception reading " + paramJarEntry.getName() + " in " + paramJarFile.getName(), localIOException);
      return null;
    }
    catch (RuntimeException localRuntimeException)
    {
      Log.w("PackageParser", "Exception reading " + paramJarEntry.getName() + " in " + paramJarFile.getName(), localRuntimeException);
    }
    return null;
  }

  private Activity parseActivity(Package paramPackage, Resources paramResources, XmlPullParser paramXmlPullParser, AttributeSet paramAttributeSet, int paramInt, String[] paramArrayOfString, boolean paramBoolean)
    throws XmlPullParserException, IOException
  {
    String str1;
    Activity localActivity;
    boolean bool1;
    TypedArray localTypedArray = paramResources.obtainAttributes(paramAttributeSet, R.styleable.AndroidManifestActivity);
    if (this.mParseActivityArgs == null)
      this.mParseActivityArgs = new ParseComponentArgs(paramPackage, paramArrayOfString, 3, 1, 2, 0, this.mSeparateProcesses, 7, 17, 5);
    ParseComponentArgs localParseComponentArgs = this.mParseActivityArgs;
    if (paramBoolean)
    {
      str1 = "<receiver>";
      label61: localParseComponentArgs.tag = str1;
      this.mParseActivityArgs.sa = localTypedArray;
      this.mParseActivityArgs.flags = paramInt;
      localActivity = new Activity(this.mParseActivityArgs, new ActivityInfo());
      if (paramArrayOfString[0] == null)
        break label132;
      localTypedArray.recycle();
      localActivity = null;
    }
    do
    {
      label132: label206: boolean bool2;
      return localActivity;
      str1 = "<activity>";
      break label61:
      bool1 = localTypedArray.hasValue(6);
      if (bool1)
        localActivity.info.exported = localTypedArray.getBoolean(6, false);
      localActivity.info.theme = localTypedArray.getResourceId(0, 0);
      String str2 = localTypedArray.getNonConfigurationString(4, 0);
      if (str2 == null)
      {
        localActivity.info.permission = paramPackage.applicationInfo.permission;
        String str4 = localTypedArray.getNonConfigurationString(8, 0);
        localActivity.info.taskAffinity = buildTaskAffinityName(paramPackage.applicationInfo.packageName, paramPackage.applicationInfo.taskAffinity, str4, paramArrayOfString);
        localActivity.info.flags = 0;
        if (localTypedArray.getBoolean(9, false))
        {
          ActivityInfo localActivityInfo11 = localActivity.info;
          localActivityInfo11.flags = (0x1 | localActivityInfo11.flags);
        }
        if (localTypedArray.getBoolean(10, false))
        {
          ActivityInfo localActivityInfo10 = localActivity.info;
          localActivityInfo10.flags = (0x2 | localActivityInfo10.flags);
        }
        if (localTypedArray.getBoolean(11, false))
        {
          ActivityInfo localActivityInfo9 = localActivity.info;
          localActivityInfo9.flags = (0x4 | localActivityInfo9.flags);
        }
        if (localTypedArray.getBoolean(21, false))
        {
          ActivityInfo localActivityInfo8 = localActivity.info;
          localActivityInfo8.flags = (0x80 | localActivityInfo8.flags);
        }
        if (localTypedArray.getBoolean(18, false))
        {
          ActivityInfo localActivityInfo7 = localActivity.info;
          localActivityInfo7.flags = (0x8 | localActivityInfo7.flags);
        }
        if (localTypedArray.getBoolean(12, false))
        {
          ActivityInfo localActivityInfo6 = localActivity.info;
          localActivityInfo6.flags = (0x10 | localActivityInfo6.flags);
        }
        if (localTypedArray.getBoolean(13, false))
        {
          ActivityInfo localActivityInfo5 = localActivity.info;
          localActivityInfo5.flags = (0x20 | localActivityInfo5.flags);
        }
        if ((0x20 & paramPackage.applicationInfo.flags) == 0)
          break label714;
        bool2 = true;
        if (localTypedArray.getBoolean(19, bool2))
        {
          label485: ActivityInfo localActivityInfo4 = localActivity.info;
          localActivityInfo4.flags = (0x40 | localActivityInfo4.flags);
        }
        if (localTypedArray.getBoolean(22, false))
        {
          ActivityInfo localActivityInfo3 = localActivity.info;
          localActivityInfo3.flags = (0x100 | localActivityInfo3.flags);
        }
        if (paramBoolean)
          break label720;
        localActivity.info.launchMode = localTypedArray.getInt(14, 0);
        localActivity.info.screenOrientation = localTypedArray.getInt(15, -1);
        localActivity.info.configChanges = localTypedArray.getInt(16, 0);
        localActivity.info.softInputMode = localTypedArray.getInt(20, 0);
      }
      while (true)
      {
        localTypedArray.recycle();
        if ((paramBoolean) && ((0x8000000 & paramPackage.applicationInfo.flags) != 0) && (localActivity.info.processName == paramPackage.packageName))
          paramArrayOfString[0] = "Heavy-weight applications can not have receivers in main process";
        if (paramArrayOfString[0] == null)
          break;
        return null;
        ActivityInfo localActivityInfo1 = localActivity.info;
        if (str2.length() > 0);
        for (String str3 = str2.toString().intern(); ; str3 = null)
        {
          localActivityInfo1.permission = str3;
          break label206:
        }
        label714: bool2 = false;
        break label485:
        label720: localActivity.info.launchMode = 0;
        localActivity.info.configChanges = 0;
      }
      int i = paramXmlPullParser.getDepth();
      while (true)
      {
        label749: int j = paramXmlPullParser.next();
        if ((j == 1) || ((j == 3) && (paramXmlPullParser.getDepth() <= i)))
          break label1136;
        if ((j == 3) || (j == 4))
          continue;
        if (paramXmlPullParser.getName().equals("intent-filter"))
        {
          ActivityIntentInfo localActivityIntentInfo = new ActivityIntentInfo(localActivity);
          if (!(paramBoolean));
          for (boolean bool3 = true; !(parseIntent(paramResources, paramXmlPullParser, paramAttributeSet, paramInt, localActivityIntentInfo, paramArrayOfString, bool3)); bool3 = false)
            return null;
          if (localActivityIntentInfo.countActions() == 0)
            Log.w("PackageParser", "No actions in intent filter at " + this.mArchiveSourcePath + " " + paramXmlPullParser.getPositionDescription());
          localActivity.intents.add(localActivityIntentInfo);
        }
        if (!(paramXmlPullParser.getName().equals("meta-data")))
          break;
        Bundle localBundle = parseMetaData(paramResources, paramXmlPullParser, paramAttributeSet, localActivity.metaData, paramArrayOfString);
        localActivity.metaData = localBundle;
        if (localBundle == null)
          return null;
      }
      Log.w("PackageParser", "Problem in package " + this.mArchiveSourcePath + ":");
      if (paramBoolean)
        Log.w("PackageParser", "Unknown element under <receiver>: " + paramXmlPullParser.getName() + " at " + this.mArchiveSourcePath + " " + paramXmlPullParser.getPositionDescription());
      while (true)
      {
        XmlUtils.skipCurrentTag(paramXmlPullParser);
        break label749:
        label1136: Log.w("PackageParser", "Unknown element under <activity>: " + paramXmlPullParser.getName() + " at " + this.mArchiveSourcePath + " " + paramXmlPullParser.getPositionDescription());
      }
    }
    while (bool1);
    ActivityInfo localActivityInfo2 = localActivity.info;
    if (localActivity.intents.size() > 0);
    for (int k = 1; ; k = 0)
    {
      localActivityInfo2.exported = k;
      return localActivity;
    }
  }

  private Activity parseActivityAlias(Package paramPackage, Resources paramResources, XmlPullParser paramXmlPullParser, AttributeSet paramAttributeSet, int paramInt, String[] paramArrayOfString)
    throws XmlPullParserException, IOException
  {
    Activity localActivity1;
    boolean bool;
    TypedArray localTypedArray = paramResources.obtainAttributes(paramAttributeSet, R.styleable.AndroidManifestActivityAlias);
    String str1 = localTypedArray.getNonConfigurationString(7, 0);
    if (str1 == null)
    {
      paramArrayOfString[0] = "<activity-alias> does not specify android:targetActivity";
      localTypedArray.recycle();
      localActivity1 = null;
    }
    do
    {
      Object localObject;
      ActivityInfo localActivityInfo3;
      return localActivity1;
      String str2 = buildClassName(paramPackage.applicationInfo.packageName, str1, paramArrayOfString);
      if (str2 == null)
      {
        localTypedArray.recycle();
        return null;
      }
      if (this.mParseActivityAliasArgs == null)
      {
        this.mParseActivityAliasArgs = new ParseComponentArgs(paramPackage, paramArrayOfString, 2, 0, 1, 0, this.mSeparateProcesses, 0, 6, 4);
        this.mParseActivityAliasArgs.tag = "<activity-alias>";
      }
      this.mParseActivityAliasArgs.sa = localTypedArray;
      this.mParseActivityAliasArgs.flags = paramInt;
      int i = paramPackage.activities.size();
      for (int j = 0; ; ++j)
      {
        int k = j;
        localObject = null;
        if (k < i)
        {
          Activity localActivity2 = (Activity)paramPackage.activities.get(j);
          if (!(str2.equals(localActivity2.info.name)))
            continue;
          localObject = localActivity2;
        }
        if (localObject != null)
          break;
        paramArrayOfString[0] = "<activity-alias> target activity " + str2 + " not found in manifest";
        localTypedArray.recycle();
        return null;
      }
      ActivityInfo localActivityInfo1 = new ActivityInfo();
      localActivityInfo1.targetActivity = str2;
      localActivityInfo1.configChanges = localObject.info.configChanges;
      localActivityInfo1.flags = localObject.info.flags;
      localActivityInfo1.icon = localObject.info.icon;
      localActivityInfo1.logo = localObject.info.logo;
      localActivityInfo1.labelRes = localObject.info.labelRes;
      localActivityInfo1.nonLocalizedLabel = localObject.info.nonLocalizedLabel;
      localActivityInfo1.launchMode = localObject.info.launchMode;
      localActivityInfo1.processName = localObject.info.processName;
      if (localActivityInfo1.descriptionRes == 0)
        localActivityInfo1.descriptionRes = localObject.info.descriptionRes;
      localActivityInfo1.screenOrientation = localObject.info.screenOrientation;
      localActivityInfo1.taskAffinity = localObject.info.taskAffinity;
      localActivityInfo1.theme = localObject.info.theme;
      localActivity1 = new Activity(this.mParseActivityAliasArgs, localActivityInfo1);
      if (paramArrayOfString[0] != null)
      {
        localTypedArray.recycle();
        return null;
      }
      bool = localTypedArray.hasValue(5);
      if (bool)
        localActivity1.info.exported = localTypedArray.getBoolean(5, false);
      String str3 = localTypedArray.getNonConfigurationString(3, 0);
      if (str3 != null)
      {
        localActivityInfo3 = localActivity1.info;
        if (str3.length() <= 0)
          break label539;
      }
      for (String str4 = str3.toString().intern(); ; str4 = null)
      {
        localActivityInfo3.permission = str4;
        localTypedArray.recycle();
        if (paramArrayOfString[0] == null)
          break;
        label539: return null;
      }
      int l = paramXmlPullParser.getDepth();
      while (true)
      {
        int i1 = paramXmlPullParser.next();
        if ((i1 == 1) || ((i1 == 3) && (paramXmlPullParser.getDepth() <= l)))
          break;
        if ((i1 == 3) || (i1 == 4))
          continue;
        if (paramXmlPullParser.getName().equals("intent-filter"))
        {
          ActivityIntentInfo localActivityIntentInfo = new ActivityIntentInfo(localActivity1);
          if (!(parseIntent(paramResources, paramXmlPullParser, paramAttributeSet, paramInt, localActivityIntentInfo, paramArrayOfString, true)))
            return null;
          if (localActivityIntentInfo.countActions() == 0)
            Log.w("PackageParser", "No actions in intent filter at " + this.mArchiveSourcePath + " " + paramXmlPullParser.getPositionDescription());
          localActivity1.intents.add(localActivityIntentInfo);
        }
        if (paramXmlPullParser.getName().equals("meta-data"))
        {
          Bundle localBundle = parseMetaData(paramResources, paramXmlPullParser, paramAttributeSet, localActivity1.metaData, paramArrayOfString);
          localActivity1.metaData = localBundle;
          if (localBundle == null);
          return null;
        }
        Log.w("PackageParser", "Unknown element under <activity-alias>: " + paramXmlPullParser.getName() + " at " + this.mArchiveSourcePath + " " + paramXmlPullParser.getPositionDescription());
        XmlUtils.skipCurrentTag(paramXmlPullParser);
      }
    }
    while (bool);
    ActivityInfo localActivityInfo2 = localActivity1.info;
    if (localActivity1.intents.size() > 0);
    for (int i2 = 1; ; i2 = 0)
    {
      localActivityInfo2.exported = i2;
      return localActivity1;
    }
  }

  private boolean parseAllMetaData(Resources paramResources, XmlPullParser paramXmlPullParser, AttributeSet paramAttributeSet, String paramString, Component paramComponent, String[] paramArrayOfString)
    throws XmlPullParserException, IOException
  {
    int i = paramXmlPullParser.getDepth();
    while (true)
    {
      int j = paramXmlPullParser.next();
      if ((j == 1) || ((j == 3) && (paramXmlPullParser.getDepth() <= i)))
        break;
      if ((j == 3) || (j == 4))
        continue;
      if (paramXmlPullParser.getName().equals("meta-data"))
      {
        Bundle localBundle = parseMetaData(paramResources, paramXmlPullParser, paramAttributeSet, paramComponent.metaData, paramArrayOfString);
        paramComponent.metaData = localBundle;
        if (localBundle == null);
        return false;
      }
      Log.w("PackageParser", "Unknown element under " + paramString + ": " + paramXmlPullParser.getName() + " at " + this.mArchiveSourcePath + " " + paramXmlPullParser.getPositionDescription());
      XmlUtils.skipCurrentTag(paramXmlPullParser);
    }
    return true;
  }

  private boolean parseApplication(Package paramPackage, Resources paramResources, XmlPullParser paramXmlPullParser, AttributeSet paramAttributeSet, int paramInt, String[] paramArrayOfString)
    throws XmlPullParserException, IOException
  {
    String str5;
    String str6;
    ApplicationInfo localApplicationInfo = paramPackage.applicationInfo;
    String str1 = paramPackage.applicationInfo.packageName;
    TypedArray localTypedArray1 = paramResources.obtainAttributes(paramAttributeSet, R.styleable.AndroidManifestApplication);
    String str2 = localTypedArray1.getNonConfigurationString(3, 0);
    if (str2 != null)
    {
      localApplicationInfo.className = buildClassName(str1, str2, paramArrayOfString);
      if (localApplicationInfo.className == null)
      {
        localTypedArray1.recycle();
        this.mParseError = -108;
        return false;
      }
    }
    String str3 = localTypedArray1.getNonConfigurationString(4, 0);
    if (str3 != null)
      localApplicationInfo.manageSpaceActivityName = buildClassName(str1, str3, paramArrayOfString);
    if (localTypedArray1.getBoolean(17, true))
    {
      localApplicationInfo.flags = (0x8000 | localApplicationInfo.flags);
      String str10 = localTypedArray1.getNonConfigurationString(16, 0);
      if (str10 != null)
      {
        localApplicationInfo.backupAgentName = buildClassName(str1, str10, paramArrayOfString);
        if (localTypedArray1.getBoolean(18, true))
          localApplicationInfo.flags = (0x10000 | localApplicationInfo.flags);
        if (localTypedArray1.getBoolean(21, false))
          localApplicationInfo.flags = (0x20000 | localApplicationInfo.flags);
      }
    }
    TypedValue localTypedValue = localTypedArray1.peekValue(1);
    if (localTypedValue != null)
    {
      int k = localTypedValue.resourceId;
      localApplicationInfo.labelRes = k;
      if (k == 0)
        localApplicationInfo.nonLocalizedLabel = localTypedValue.coerceToString();
    }
    localApplicationInfo.icon = localTypedArray1.getResourceId(2, 0);
    localApplicationInfo.theme = localTypedArray1.getResourceId(0, 0);
    localApplicationInfo.descriptionRes = localTypedArray1.getResourceId(13, 0);
    if (((paramInt & 0x1) != 0) && (localTypedArray1.getBoolean(8, false)))
      localApplicationInfo.flags = (0x8 | localApplicationInfo.flags);
    if ((paramInt & 0x10) != 0)
      localApplicationInfo.flags = (0x20000000 | localApplicationInfo.flags);
    if ((paramInt & 0x20) != 0)
      localApplicationInfo.flags = (0x40000 | localApplicationInfo.flags);
    if (localTypedArray1.getBoolean(10, false))
      localApplicationInfo.flags = (0x2 | localApplicationInfo.flags);
    if (localTypedArray1.getBoolean(20, false))
      localApplicationInfo.flags = (0x4000 | localApplicationInfo.flags);
    if (localTypedArray1.getBoolean(7, true))
      localApplicationInfo.flags = (0x4 | localApplicationInfo.flags);
    if (localTypedArray1.getBoolean(14, false))
      localApplicationInfo.flags = (0x20 | localApplicationInfo.flags);
    if (localTypedArray1.getBoolean(5, true))
      localApplicationInfo.flags = (0x40 | localApplicationInfo.flags);
    if (localTypedArray1.getBoolean(15, false))
      localApplicationInfo.flags = (0x100 | localApplicationInfo.flags);
    if (localTypedArray1.getBoolean(22, false))
      localApplicationInfo.flags = (0x40000000 | localApplicationInfo.flags);
    String str4 = localTypedArray1.getNonConfigurationString(6, 0);
    if ((str4 != null) && (str4.length() > 0))
    {
      str5 = str4.intern();
      label559: localApplicationInfo.permission = str5;
      if (paramPackage.applicationInfo.targetSdkVersion < 8)
        break label702;
      str6 = localTypedArray1.getNonConfigurationString(12, 0);
      label588: localApplicationInfo.taskAffinity = buildTaskAffinityName(localApplicationInfo.packageName, localApplicationInfo.packageName, str6, paramArrayOfString);
      if (paramArrayOfString[0] == null)
        if (paramPackage.applicationInfo.targetSdkVersion < 8)
          break label714;
    }
    for (String str9 = localTypedArray1.getNonConfigurationString(11, 0); ; str9 = localTypedArray1.getNonResourceString(11))
    {
      localApplicationInfo.processName = buildProcessName(localApplicationInfo.packageName, null, str9, paramInt, this.mSeparateProcesses, paramArrayOfString);
      localApplicationInfo.enabled = localTypedArray1.getBoolean(9, true);
      localTypedArray1.recycle();
      if (paramArrayOfString[0] == null)
        break;
      this.mParseError = -108;
      return false;
      str5 = null;
      break label559:
      label702: str6 = localTypedArray1.getNonResourceString(12);
      label714: break label588:
    }
    int i = paramXmlPullParser.getDepth();
    while (true)
    {
      label734: int j = paramXmlPullParser.next();
      if ((j == 1) || ((j == 3) && (paramXmlPullParser.getDepth() <= i)))
        break;
      if ((j == 3) || (j == 4))
        continue;
      String str7 = paramXmlPullParser.getName();
      if (str7.equals("activity"))
      {
        Activity localActivity3 = parseActivity(paramPackage, paramResources, paramXmlPullParser, paramAttributeSet, paramInt, paramArrayOfString, false);
        if (localActivity3 == null)
        {
          this.mParseError = -108;
          return false;
        }
        paramPackage.activities.add(localActivity3);
      }
      if (str7.equals("receiver"))
      {
        Activity localActivity2 = parseActivity(paramPackage, paramResources, paramXmlPullParser, paramAttributeSet, paramInt, paramArrayOfString, true);
        if (localActivity2 == null)
        {
          this.mParseError = -108;
          return false;
        }
        paramPackage.receivers.add(localActivity2);
      }
      if (str7.equals("service"))
      {
        Service localService = parseService(paramPackage, paramResources, paramXmlPullParser, paramAttributeSet, paramInt, paramArrayOfString);
        if (localService == null)
        {
          this.mParseError = -108;
          return false;
        }
        paramPackage.services.add(localService);
      }
      if (str7.equals("provider"))
      {
        Provider localProvider = parseProvider(paramPackage, paramResources, paramXmlPullParser, paramAttributeSet, paramInt, paramArrayOfString);
        if (localProvider == null)
        {
          this.mParseError = -108;
          return false;
        }
        paramPackage.providers.add(localProvider);
      }
      if (str7.equals("activity-alias"))
      {
        Activity localActivity1 = parseActivityAlias(paramPackage, paramResources, paramXmlPullParser, paramAttributeSet, paramInt, paramArrayOfString);
        if (localActivity1 == null)
        {
          this.mParseError = -108;
          return false;
        }
        paramPackage.activities.add(localActivity1);
      }
      if (paramXmlPullParser.getName().equals("meta-data"))
      {
        Bundle localBundle = parseMetaData(paramResources, paramXmlPullParser, paramAttributeSet, paramPackage.mAppMetaData, paramArrayOfString);
        paramPackage.mAppMetaData = localBundle;
        if (localBundle != null)
          continue;
        this.mParseError = -108;
        return false;
      }
      if (str7.equals("uses-library"))
      {
        TypedArray localTypedArray2 = paramResources.obtainAttributes(paramAttributeSet, R.styleable.AndroidManifestUsesLibrary);
        String str8 = localTypedArray2.getNonResourceString(0);
        boolean bool = localTypedArray2.getBoolean(1, true);
        localTypedArray2.recycle();
        if (str8 != null)
        {
          if (!(bool))
            break label1201;
          if (paramPackage.usesLibraries == null)
            paramPackage.usesLibraries = new ArrayList();
          if (!(paramPackage.usesLibraries.contains(str8)))
            paramPackage.usesLibraries.add(str8.intern());
        }
        while (true)
        {
          XmlUtils.skipCurrentTag(paramXmlPullParser);
          break label734:
          if (paramPackage.usesOptionalLibraries == null)
            label1201: paramPackage.usesOptionalLibraries = new ArrayList();
          if (paramPackage.usesOptionalLibraries.contains(str8))
            continue;
          paramPackage.usesOptionalLibraries.add(str8.intern());
        }
      }
      if (str7.equals("uses-package"))
        XmlUtils.skipCurrentTag(paramXmlPullParser);
      Log.w("PackageParser", "Unknown element under <application>: " + str7 + " at " + this.mArchiveSourcePath + " " + paramXmlPullParser.getPositionDescription());
      XmlUtils.skipCurrentTag(paramXmlPullParser);
    }
    return true;
  }

  private Instrumentation parseInstrumentation(Package paramPackage, Resources paramResources, XmlPullParser paramXmlPullParser, AttributeSet paramAttributeSet, String[] paramArrayOfString)
    throws XmlPullParserException, IOException
  {
    TypedArray localTypedArray = paramResources.obtainAttributes(paramAttributeSet, R.styleable.AndroidManifestInstrumentation);
    if (this.mParseInstrumentationArgs == null)
    {
      this.mParseInstrumentationArgs = new ParsePackageItemArgs(paramPackage, paramArrayOfString, 2, 0, 1, 0);
      this.mParseInstrumentationArgs.tag = "<instrumentation>";
    }
    this.mParseInstrumentationArgs.sa = localTypedArray;
    Instrumentation localInstrumentation = new Instrumentation(this.mParseInstrumentationArgs, new InstrumentationInfo());
    if (paramArrayOfString[0] != null)
    {
      localTypedArray.recycle();
      this.mParseError = -108;
      return null;
    }
    String str1 = localTypedArray.getNonResourceString(3);
    InstrumentationInfo localInstrumentationInfo = localInstrumentation.info;
    if (str1 != null);
    for (String str2 = str1.intern(); ; str2 = null)
    {
      localInstrumentationInfo.targetPackage = str2;
      localInstrumentation.info.handleProfiling = localTypedArray.getBoolean(4, false);
      localInstrumentation.info.functionalTest = localTypedArray.getBoolean(5, false);
      localTypedArray.recycle();
      if (localInstrumentation.info.targetPackage != null)
        break;
      paramArrayOfString[0] = "<instrumentation> does not specify targetPackage";
      this.mParseError = -108;
      return null;
    }
    if (!(parseAllMetaData(paramResources, paramXmlPullParser, paramAttributeSet, "<instrumentation>", localInstrumentation, paramArrayOfString)))
    {
      this.mParseError = -108;
      return null;
    }
    paramPackage.instrumentation.add(localInstrumentation);
    return localInstrumentation;
  }

  private boolean parseIntent(Resources paramResources, XmlPullParser paramXmlPullParser, AttributeSet paramAttributeSet, int paramInt, IntentInfo paramIntentInfo, String[] paramArrayOfString, boolean paramBoolean)
    throws XmlPullParserException, IOException
  {
    TypedArray localTypedArray1 = paramResources.obtainAttributes(paramAttributeSet, R.styleable.AndroidManifestIntentFilter);
    paramIntentInfo.setPriority(localTypedArray1.getInt(2, 0));
    TypedValue localTypedValue = localTypedArray1.peekValue(0);
    if (localTypedValue != null)
    {
      int k = localTypedValue.resourceId;
      paramIntentInfo.labelRes = k;
      if (k == 0)
        paramIntentInfo.nonLocalizedLabel = localTypedValue.coerceToString();
    }
    paramIntentInfo.icon = localTypedArray1.getResourceId(1, 0);
    localTypedArray1.recycle();
    int i = paramXmlPullParser.getDepth();
    while (true)
    {
      int j = paramXmlPullParser.next();
      if ((j == 1) || ((j == 3) && (paramXmlPullParser.getDepth() <= i)))
        break;
      if ((j == 3) || (j == 4))
        continue;
      String str1 = paramXmlPullParser.getName();
      if (str1.equals("action"))
      {
        String str10 = paramAttributeSet.getAttributeValue("http://schemas.android.com/apk/res/android", "name");
        if ((str10 == null) || (str10 == ""))
        {
          paramArrayOfString[0] = "No value supplied for <android:name>";
          return false;
        }
        XmlUtils.skipCurrentTag(paramXmlPullParser);
        paramIntentInfo.addAction(str10);
      }
      if (str1.equals("category"))
      {
        String str9 = paramAttributeSet.getAttributeValue("http://schemas.android.com/apk/res/android", "name");
        if ((str9 == null) || (str9 == ""))
        {
          paramArrayOfString[0] = "No value supplied for <android:name>";
          return false;
        }
        XmlUtils.skipCurrentTag(paramXmlPullParser);
        paramIntentInfo.addCategory(str9);
      }
      if (str1.equals("data"))
      {
        TypedArray localTypedArray2 = paramResources.obtainAttributes(paramAttributeSet, R.styleable.AndroidManifestData);
        String str2 = localTypedArray2.getNonConfigurationString(0, 0);
        if (str2 != null);
        try
        {
          paramIntentInfo.addDataType(str2);
          String str3 = localTypedArray2.getNonConfigurationString(1, 0);
          if (str3 != null)
            paramIntentInfo.addDataScheme(str3);
          String str4 = localTypedArray2.getNonConfigurationString(2, 0);
          String str5 = localTypedArray2.getNonConfigurationString(3, 0);
          if (str4 != null)
            paramIntentInfo.addDataAuthority(str4, str5);
          String str6 = localTypedArray2.getNonConfigurationString(4, 0);
          if (str6 != null)
            paramIntentInfo.addDataPath(str6, 0);
          String str7 = localTypedArray2.getNonConfigurationString(5, 0);
          if (str7 != null)
            paramIntentInfo.addDataPath(str7, 1);
          String str8 = localTypedArray2.getNonConfigurationString(6, 0);
          if (str8 != null)
            paramIntentInfo.addDataPath(str8, 2);
          localTypedArray2.recycle();
          XmlUtils.skipCurrentTag(paramXmlPullParser);
        }
        catch (IntentFilter.MalformedMimeTypeException localMalformedMimeTypeException)
        {
          paramArrayOfString[0] = localMalformedMimeTypeException.toString();
          localTypedArray2.recycle();
          return false;
        }
      }
      Log.w("PackageParser", "Unknown element under <intent-filter>: " + paramXmlPullParser.getName() + " at " + this.mArchiveSourcePath + " " + paramXmlPullParser.getPositionDescription());
      XmlUtils.skipCurrentTag(paramXmlPullParser);
    }
    paramIntentInfo.hasDefault = paramIntentInfo.hasCategory("android.intent.category.DEFAULT");
    return true;
  }

  private Bundle parseMetaData(Resources paramResources, XmlPullParser paramXmlPullParser, AttributeSet paramAttributeSet, Bundle paramBundle, String[] paramArrayOfString)
    throws XmlPullParserException, IOException
  {
    TypedArray localTypedArray = paramResources.obtainAttributes(paramAttributeSet, R.styleable.AndroidManifestMetaData);
    if (paramBundle == null)
      paramBundle = new Bundle();
    String str1 = localTypedArray.getNonConfigurationString(0, 0);
    if (str1 == null)
    {
      paramArrayOfString[0] = "<meta-data> requires an android:name attribute";
      localTypedArray.recycle();
      return null;
    }
    String str2 = str1.intern();
    TypedValue localTypedValue1 = localTypedArray.peekValue(2);
    if ((localTypedValue1 != null) && (localTypedValue1.resourceId != 0))
      paramBundle.putInt(str2, localTypedValue1.resourceId);
    while (true)
    {
      label92: localTypedArray.recycle();
      XmlUtils.skipCurrentTag(paramXmlPullParser);
      return paramBundle;
      TypedValue localTypedValue2 = localTypedArray.peekValue(1);
      if (localTypedValue2 != null)
      {
        if (localTypedValue2.type == 3)
        {
          CharSequence localCharSequence = localTypedValue2.coerceToString();
          String str3 = null;
          if (localCharSequence != null)
            str3 = localCharSequence.toString().intern();
          paramBundle.putString(str2, str3);
        }
        if (localTypedValue2.type == 18)
        {
          if (localTypedValue2.data != 0);
          for (boolean bool = true; ; bool = false)
          {
            paramBundle.putBoolean(str2, bool);
            break label92:
          }
        }
        if ((localTypedValue2.type >= 16) && (localTypedValue2.type <= 31))
          paramBundle.putInt(str2, localTypedValue2.data);
        if (localTypedValue2.type == 4)
          paramBundle.putFloat(str2, localTypedValue2.getFloat());
        Log.w("PackageParser", "<meta-data> only supports string, integer, float, color, boolean, and resource reference types: " + paramXmlPullParser.getName() + " at " + this.mArchiveSourcePath + " " + paramXmlPullParser.getPositionDescription());
      }
      paramArrayOfString[0] = "<meta-data> requires an android:value or android:resource attribute";
      paramBundle = null;
    }
  }

  private Package parsePackage(Resources paramResources, XmlResourceParser paramXmlResourceParser, int paramInt, String[] paramArrayOfString)
    throws XmlPullParserException, IOException
  {
    Package localPackage;
    int i3;
    StringBuilder localStringBuilder;
    int i7;
    NewPermissionInfo localNewPermissionInfo;
    this.mParseInstrumentationArgs = null;
    this.mParseActivityArgs = null;
    this.mParseServiceArgs = null;
    this.mParseProviderArgs = null;
    String str1 = parsePackageName(paramXmlResourceParser, paramXmlResourceParser, paramInt, paramArrayOfString);
    if (str1 == null)
    {
      this.mParseError = -106;
      localPackage = null;
    }
    do
    {
      return localPackage;
      localPackage = new Package(str1);
      int i = 0;
      TypedArray localTypedArray1 = paramResources.obtainAttributes(paramXmlResourceParser, R.styleable.AndroidManifest);
      localPackage.mVersionCode = localTypedArray1.getInteger(1, 0);
      localPackage.mVersionName = localTypedArray1.getNonConfigurationString(2, 0);
      if (localPackage.mVersionName != null)
        localPackage.mVersionName = localPackage.mVersionName.intern();
      String str2 = localTypedArray1.getNonConfigurationString(0, 0);
      if ((str2 != null) && (str2.length() > 0))
      {
        String str12 = validateName(str2, true);
        if ((str12 != null) && (!("android".equals(str1))))
        {
          paramArrayOfString[0] = "<manifest> specifies bad sharedUserId name \"" + str2 + "\": " + str12;
          this.mParseError = -107;
          return null;
        }
        localPackage.mSharedUserId = str2.intern();
        localPackage.mSharedUserLabel = localTypedArray1.getResourceId(3, 0);
      }
      localTypedArray1.recycle();
      localPackage.installLocation = localTypedArray1.getInteger(4, -1);
      localPackage.applicationInfo.installLocation = localPackage.installLocation;
      int j = 1;
      int k = 1;
      int l = 1;
      int i1 = 1;
      int i2 = 1;
      i3 = 1;
      int i4 = paramXmlResourceParser.getDepth();
      while (true)
      {
        label284: int i5 = paramXmlResourceParser.next();
        if ((i5 == 1) || ((i5 == 3) && (paramXmlResourceParser.getDepth() <= i4)))
          break;
        if ((i5 == 3) || (i5 == 4))
          continue;
        String str3 = paramXmlResourceParser.getName();
        if (str3.equals("application"))
        {
          if (i != 0)
          {
            Log.w("PackageParser", "<manifest> has more than one <application>");
            XmlUtils.skipCurrentTag(paramXmlResourceParser);
          }
          i = 1;
          if (!(parseApplication(localPackage, paramResources, paramXmlResourceParser, paramXmlResourceParser, paramInt, paramArrayOfString)));
          return null;
        }
        if (str3.equals("permission-group"))
        {
          if (parsePermissionGroup(localPackage, paramResources, paramXmlResourceParser, paramXmlResourceParser, paramArrayOfString) == null);
          return null;
        }
        if (str3.equals("permission"))
        {
          if (parsePermission(localPackage, paramResources, paramXmlResourceParser, paramXmlResourceParser, paramArrayOfString) == null);
          return null;
        }
        if (str3.equals("permission-tree"))
        {
          if (parsePermissionTree(localPackage, paramResources, paramXmlResourceParser, paramXmlResourceParser, paramArrayOfString) == null);
          return null;
        }
        if (str3.equals("uses-permission"))
        {
          TypedArray localTypedArray9 = paramResources.obtainAttributes(paramXmlResourceParser, R.styleable.AndroidManifestUsesPermission);
          String str11 = localTypedArray9.getNonResourceString(0);
          localTypedArray9.recycle();
          if ((str11 != null) && (!(localPackage.requestedPermissions.contains(str11))))
            localPackage.requestedPermissions.add(str11.intern());
          XmlUtils.skipCurrentTag(paramXmlResourceParser);
        }
        if (str3.equals("uses-configuration"))
        {
          ConfigurationInfo localConfigurationInfo1 = new ConfigurationInfo();
          TypedArray localTypedArray2 = paramResources.obtainAttributes(paramXmlResourceParser, R.styleable.AndroidManifestUsesConfiguration);
          localConfigurationInfo1.reqTouchScreen = localTypedArray2.getInt(0, 0);
          localConfigurationInfo1.reqKeyboardType = localTypedArray2.getInt(1, 0);
          if (localTypedArray2.getBoolean(2, false))
            localConfigurationInfo1.reqInputFeatures = (0x1 | localConfigurationInfo1.reqInputFeatures);
          localConfigurationInfo1.reqNavigation = localTypedArray2.getInt(3, 0);
          if (localTypedArray2.getBoolean(4, false))
            localConfigurationInfo1.reqInputFeatures = (0x2 | localConfigurationInfo1.reqInputFeatures);
          localTypedArray2.recycle();
          localPackage.configPreferences.add(localConfigurationInfo1);
          XmlUtils.skipCurrentTag(paramXmlResourceParser);
        }
        if (str3.equals("uses-feature"))
        {
          FeatureInfo localFeatureInfo = new FeatureInfo();
          TypedArray localTypedArray3 = paramResources.obtainAttributes(paramXmlResourceParser, R.styleable.AndroidManifestUsesFeature);
          localFeatureInfo.name = localTypedArray3.getNonResourceString(0);
          if (localFeatureInfo.name == null)
            localFeatureInfo.reqGlEsVersion = localTypedArray3.getInt(1, 0);
          if (localTypedArray3.getBoolean(2, true))
            localFeatureInfo.flags = (0x1 | localFeatureInfo.flags);
          localTypedArray3.recycle();
          if (localPackage.reqFeatures == null)
            localPackage.reqFeatures = new ArrayList();
          localPackage.reqFeatures.add(localFeatureInfo);
          if (localFeatureInfo.name == null)
          {
            ConfigurationInfo localConfigurationInfo2 = new ConfigurationInfo();
            localConfigurationInfo2.reqGlEsVersion = localFeatureInfo.reqGlEsVersion;
            localPackage.configPreferences.add(localConfigurationInfo2);
          }
          XmlUtils.skipCurrentTag(paramXmlResourceParser);
        }
        if (str3.equals("uses-sdk"))
        {
          int i9;
          if (SDK_VERSION > 0)
          {
            TypedArray localTypedArray8 = paramResources.obtainAttributes(paramXmlResourceParser, R.styleable.AndroidManifestUsesSdk);
            TypedValue localTypedValue1 = localTypedArray8.peekValue(0);
            String str7 = null;
            int i8 = 0;
            String str8 = null;
            i9 = 0;
            if (localTypedValue1 != null)
            {
              if ((localTypedValue1.type != 3) || (localTypedValue1.string == null))
                break label1047;
              str7 = localTypedValue1.string.toString();
              str8 = str7;
            }
            label921: TypedValue localTypedValue2 = localTypedArray8.peekValue(1);
            if (localTypedValue2 != null)
            {
              if ((localTypedValue2.type != 3) || (localTypedValue2.string == null))
                break label1067;
              str7 = localTypedValue2.string.toString();
              str8 = str7;
            }
            label965: localTypedArray8.recycle();
            if (str7 != null)
            {
              String str10 = SDK_CODENAME;
              if (str7.equals(str10))
                break label1174;
              if (SDK_CODENAME != null)
                paramArrayOfString[0] = "Requires development platform " + str7 + " (current platform is " + SDK_CODENAME + ")";
              while (true)
              {
                this.mParseError = -12;
                return null;
                label1047: i8 = localTypedValue1.data;
                i9 = i8;
                str7 = null;
                str8 = null;
                break label921:
                label1067: i9 = localTypedValue2.data;
                break label965:
                paramArrayOfString[0] = "Requires development platform " + str7 + " but this is a release platform.";
              }
            }
            int i10 = SDK_VERSION;
            if (i8 > i10)
            {
              paramArrayOfString[0] = "Requires newer sdk version #" + i8 + " (current version is #" + SDK_VERSION + ")";
              this.mParseError = -12;
              return null;
            }
            label1174: if (str8 == null)
              break label1303;
            String str9 = SDK_CODENAME;
            if (!(str8.equals(str9)))
            {
              if (SDK_CODENAME != null)
                paramArrayOfString[0] = "Requires development platform " + str8 + " (current platform is " + SDK_CODENAME + ")";
              while (true)
              {
                this.mParseError = -12;
                return null;
                paramArrayOfString[0] = "Requires development platform " + str8 + " but this is a release platform.";
              }
            }
          }
          for (localPackage.applicationInfo.targetSdkVersion = 10000; ; localPackage.applicationInfo.targetSdkVersion = i9)
          {
            XmlUtils.skipCurrentTag(paramXmlResourceParser);
            label1303: break label284:
          }
        }
        if (str3.equals("supports-screens"))
        {
          TypedArray localTypedArray7 = paramResources.obtainAttributes(paramXmlResourceParser, R.styleable.AndroidManifestSupportsScreens);
          j = localTypedArray7.getInteger(1, j);
          k = localTypedArray7.getInteger(2, k);
          l = localTypedArray7.getInteger(3, l);
          i1 = localTypedArray7.getInteger(5, i1);
          i2 = localTypedArray7.getInteger(4, i2);
          i3 = localTypedArray7.getInteger(0, i3);
          localTypedArray7.recycle();
          XmlUtils.skipCurrentTag(paramXmlResourceParser);
        }
        if (str3.equals("protected-broadcast"))
        {
          TypedArray localTypedArray6 = paramResources.obtainAttributes(paramXmlResourceParser, R.styleable.AndroidManifestProtectedBroadcast);
          String str6 = localTypedArray6.getNonResourceString(0);
          localTypedArray6.recycle();
          if ((str6 != null) && ((paramInt & 0x1) != 0))
          {
            if (localPackage.protectedBroadcasts == null)
              localPackage.protectedBroadcasts = new ArrayList();
            if (!(localPackage.protectedBroadcasts.contains(str6)))
              localPackage.protectedBroadcasts.add(str6.intern());
          }
          XmlUtils.skipCurrentTag(paramXmlResourceParser);
        }
        if (str3.equals("instrumentation"))
        {
          if (parseInstrumentation(localPackage, paramResources, paramXmlResourceParser, paramXmlResourceParser, paramArrayOfString) == null);
          return null;
        }
        if (str3.equals("original-package"))
        {
          TypedArray localTypedArray5 = paramResources.obtainAttributes(paramXmlResourceParser, R.styleable.AndroidManifestOriginalPackage);
          String str5 = localTypedArray5.getNonConfigurationString(0, 0);
          if (!(localPackage.packageName.equals(str5)))
          {
            if (localPackage.mOriginalPackages == null)
            {
              localPackage.mOriginalPackages = new ArrayList();
              localPackage.mRealPackage = localPackage.packageName;
            }
            localPackage.mOriginalPackages.add(str5);
          }
          localTypedArray5.recycle();
          XmlUtils.skipCurrentTag(paramXmlResourceParser);
        }
        if (str3.equals("adopt-permissions"))
        {
          TypedArray localTypedArray4 = paramResources.obtainAttributes(paramXmlResourceParser, R.styleable.AndroidManifestOriginalPackage);
          String str4 = localTypedArray4.getNonConfigurationString(0, 0);
          localTypedArray4.recycle();
          if (str4 != null)
          {
            if (localPackage.mAdoptPermissions == null)
              localPackage.mAdoptPermissions = new ArrayList();
            localPackage.mAdoptPermissions.add(str4);
          }
          XmlUtils.skipCurrentTag(paramXmlResourceParser);
        }
        if (str3.equals("uses-gl-texture"))
          XmlUtils.skipCurrentTag(paramXmlResourceParser);
        if (str3.equals("compatible-screens"))
          XmlUtils.skipCurrentTag(paramXmlResourceParser);
        if (str3.equals("eat-comment"))
          XmlUtils.skipCurrentTag(paramXmlResourceParser);
        Log.w("PackageParser", "Unknown element under <manifest>: " + paramXmlResourceParser.getName() + " at " + this.mArchiveSourcePath + " " + paramXmlResourceParser.getPositionDescription());
        XmlUtils.skipCurrentTag(paramXmlResourceParser);
      }
      if ((i == 0) && (localPackage.instrumentation.size() == 0))
      {
        paramArrayOfString[0] = "<manifest> does not contain an <application> or <instrumentation>";
        this.mParseError = -109;
      }
      int i6 = NEW_PERMISSIONS.length;
      localStringBuilder = null;
      i7 = 0;
      if (i7 < i6)
      {
        label1870: localNewPermissionInfo = NEW_PERMISSIONS[i7];
        if (localPackage.applicationInfo.targetSdkVersion < localNewPermissionInfo.sdkVersion)
          break label2162;
      }
      if (localStringBuilder != null)
        Log.i("PackageParser", localStringBuilder.toString());
      if ((j < 0) || ((j > 0) && (localPackage.applicationInfo.targetSdkVersion >= 4)))
      {
        ApplicationInfo localApplicationInfo1 = localPackage.applicationInfo;
        localApplicationInfo1.flags = (0x200 | localApplicationInfo1.flags);
      }
      if (k != 0)
      {
        ApplicationInfo localApplicationInfo6 = localPackage.applicationInfo;
        localApplicationInfo6.flags = (0x400 | localApplicationInfo6.flags);
      }
      if ((l < 0) || ((l > 0) && (localPackage.applicationInfo.targetSdkVersion >= 4)))
      {
        ApplicationInfo localApplicationInfo2 = localPackage.applicationInfo;
        localApplicationInfo2.flags = (0x800 | localApplicationInfo2.flags);
      }
      if ((i1 < 0) || ((i1 > 0) && (localPackage.applicationInfo.targetSdkVersion >= 9)))
      {
        ApplicationInfo localApplicationInfo3 = localPackage.applicationInfo;
        localApplicationInfo3.flags = (0x80000 | localApplicationInfo3.flags);
      }
      if ((i2 >= 0) && (((i2 <= 0) || (localPackage.applicationInfo.targetSdkVersion < 4))))
        continue;
      ApplicationInfo localApplicationInfo4 = localPackage.applicationInfo;
      localApplicationInfo4.flags = (0x1000 | localApplicationInfo4.flags);
    }
    while ((i3 >= 0) && (((i3 <= 0) || (localPackage.applicationInfo.targetSdkVersion < 4))));
    ApplicationInfo localApplicationInfo5 = localPackage.applicationInfo;
    localApplicationInfo5.flags = (0x2000 | localApplicationInfo5.flags);
    return localPackage;
    if (!(localPackage.requestedPermissions.contains(localNewPermissionInfo.name)))
    {
      label2162: if (localStringBuilder != null)
        break label2246;
      localStringBuilder = new StringBuilder(128);
      localStringBuilder.append(localPackage.packageName);
      localStringBuilder.append(": compat added ");
    }
    while (true)
    {
      localStringBuilder.append(localNewPermissionInfo.name);
      localPackage.requestedPermissions.add(localNewPermissionInfo.name);
      ++i7;
      break label1870:
      label2246: localStringBuilder.append(' ');
    }
  }

  private boolean parsePackageItemInfo(Package paramPackage, PackageItemInfo paramPackageItemInfo, String[] paramArrayOfString, String paramString, TypedArray paramTypedArray, int paramInt1, int paramInt2, int paramInt3, int paramInt4)
  {
    String str = paramTypedArray.getNonConfigurationString(paramInt1, 0);
    if (str == null)
      paramArrayOfString[0] = paramString + " does not specify android:name";
    do
    {
      return false;
      paramPackageItemInfo.name = buildClassName(paramPackage.applicationInfo.packageName, str, paramArrayOfString);
    }
    while (paramPackageItemInfo.name == null);
    int i = paramTypedArray.getResourceId(paramInt3, 0);
    if (i != 0)
    {
      paramPackageItemInfo.icon = i;
      paramPackageItemInfo.nonLocalizedLabel = null;
    }
    TypedValue localTypedValue = paramTypedArray.peekValue(paramInt2);
    if (localTypedValue != null)
    {
      int j = localTypedValue.resourceId;
      paramPackageItemInfo.labelRes = j;
      if (j == 0)
        paramPackageItemInfo.nonLocalizedLabel = localTypedValue.coerceToString();
    }
    paramPackageItemInfo.packageName = paramPackage.packageName;
    return true;
  }

  // ERROR //
  public static PackageLite parsePackageLite(String paramString, int paramInt)
  {
    // Byte code:
    //   0: aconst_null
    //   1: astore_2
    //   2: new 1127	android/content/res/AssetManager
    //   5: dup
    //   6: invokespecial 1128	android/content/res/AssetManager:<init>	()V
    //   9: astore_3
    //   10: aload_3
    //   11: aload_3
    //   12: aload_0
    //   13: invokevirtual 1132	android/content/res/AssetManager:addAssetPath	(Ljava/lang/String;)I
    //   16: ldc_w 1134
    //   19: invokevirtual 1138	android/content/res/AssetManager:openXmlResourceParser	(ILjava/lang/String;)Landroid/content/res/XmlResourceParser;
    //   22: astore 6
    //   24: iconst_1
    //   25: anewarray 80	java/lang/String
    //   28: astore 7
    //   30: aload 6
    //   32: aload 6
    //   34: iload_1
    //   35: aload 7
    //   37: invokestatic 1141	android/content/pm/PackageParser:parsePackageLite	(Lorg/xmlpull/v1/XmlPullParser;Landroid/util/AttributeSet;I[Ljava/lang/String;)Landroid/content/pm/PackageParser$PackageLite;
    //   40: astore 15
    //   42: aload 15
    //   44: astore 11
    //   46: aload 6
    //   48: ifnull +10 -> 58
    //   51: aload 6
    //   53: invokeinterface 1142 1 0
    //   58: aload_3
    //   59: ifnull +7 -> 66
    //   62: aload_3
    //   63: invokevirtual 1143	android/content/res/AssetManager:close	()V
    //   66: aload 11
    //   68: ifnonnull +179 -> 247
    //   71: ldc 35
    //   73: new 115	java/lang/StringBuilder
    //   76: dup
    //   77: invokespecial 116	java/lang/StringBuilder:<init>	()V
    //   80: ldc_w 1145
    //   83: invokevirtual 122	java/lang/StringBuilder:append	(Ljava/lang/String;)Ljava/lang/StringBuilder;
    //   86: aload 7
    //   88: iconst_0
    //   89: aaload
    //   90: invokevirtual 122	java/lang/StringBuilder:append	(Ljava/lang/String;)Ljava/lang/StringBuilder;
    //   93: invokevirtual 126	java/lang/StringBuilder:toString	()Ljava/lang/String;
    //   96: invokestatic 1148	android/util/Log:e	(Ljava/lang/String;Ljava/lang/String;)I
    //   99: pop
    //   100: aconst_null
    //   101: areturn
    //   102: astore 4
    //   104: aload_2
    //   105: ifnull +7 -> 112
    //   108: aload_2
    //   109: invokevirtual 1143	android/content/res/AssetManager:close	()V
    //   112: ldc 35
    //   114: new 115	java/lang/StringBuilder
    //   117: dup
    //   118: invokespecial 116	java/lang/StringBuilder:<init>	()V
    //   121: ldc_w 1150
    //   124: invokevirtual 122	java/lang/StringBuilder:append	(Ljava/lang/String;)Ljava/lang/StringBuilder;
    //   127: aload_0
    //   128: invokevirtual 122	java/lang/StringBuilder:append	(Ljava/lang/String;)Ljava/lang/StringBuilder;
    //   131: invokevirtual 126	java/lang/StringBuilder:toString	()Ljava/lang/String;
    //   134: aload 4
    //   136: invokestatic 517	android/util/Log:w	(Ljava/lang/String;Ljava/lang/String;Ljava/lang/Throwable;)I
    //   139: pop
    //   140: aconst_null
    //   141: areturn
    //   142: astore 13
    //   144: ldc 35
    //   146: aload_0
    //   147: aload 13
    //   149: invokestatic 517	android/util/Log:w	(Ljava/lang/String;Ljava/lang/String;Ljava/lang/Throwable;)I
    //   152: pop
    //   153: aload 6
    //   155: ifnull +10 -> 165
    //   158: aload 6
    //   160: invokeinterface 1142 1 0
    //   165: aconst_null
    //   166: astore 11
    //   168: aload_3
    //   169: ifnull -103 -> 66
    //   172: aload_3
    //   173: invokevirtual 1143	android/content/res/AssetManager:close	()V
    //   176: aconst_null
    //   177: astore 11
    //   179: goto -113 -> 66
    //   182: astore 9
    //   184: ldc 35
    //   186: aload_0
    //   187: aload 9
    //   189: invokestatic 517	android/util/Log:w	(Ljava/lang/String;Ljava/lang/String;Ljava/lang/Throwable;)I
    //   192: pop
    //   193: aload 6
    //   195: ifnull +10 -> 205
    //   198: aload 6
    //   200: invokeinterface 1142 1 0
    //   205: aconst_null
    //   206: astore 11
    //   208: aload_3
    //   209: ifnull -143 -> 66
    //   212: aload_3
    //   213: invokevirtual 1143	android/content/res/AssetManager:close	()V
    //   216: aconst_null
    //   217: astore 11
    //   219: goto -153 -> 66
    //   222: astore 8
    //   224: aload 6
    //   226: ifnull +10 -> 236
    //   229: aload 6
    //   231: invokeinterface 1142 1 0
    //   236: aload_3
    //   237: ifnull +7 -> 244
    //   240: aload_3
    //   241: invokevirtual 1143	android/content/res/AssetManager:close	()V
    //   244: aload 8
    //   246: athrow
    //   247: aload 11
    //   249: areturn
    //   250: astore 4
    //   252: aload_3
    //   253: astore_2
    //   254: goto -150 -> 104
    //
    // Exception table:
    //   from	to	target	type
    //   2	10	102	java/lang/Exception
    //   30	42	142	IOException
    //   30	42	182	XmlPullParserException
    //   30	42	222	finally
    //   144	153	222	finally
    //   184	193	222	finally
    //   10	24	250	java/lang/Exception
  }

  private static PackageLite parsePackageLite(XmlPullParser paramXmlPullParser, AttributeSet paramAttributeSet, int paramInt, String[] paramArrayOfString)
    throws IOException, XmlPullParserException
  {
    int i;
    do
      i = paramXmlPullParser.next();
    while ((i != 2) && (i != 1));
    if (i != 2)
    {
      paramArrayOfString[0] = "No start tag found";
      return null;
    }
    if (((paramInt & 0x2) == 0) || (!(paramXmlPullParser.getName().equals("manifest"))))
    {
      paramArrayOfString[0] = "No <manifest> tag";
      return null;
    }
    String str1 = paramAttributeSet.getAttributeValue(null, "package");
    if ((str1 == null) || (str1.length() == 0))
    {
      paramArrayOfString[0] = "<manifest> does not specify package";
      return null;
    }
    String str2 = validateName(str1, true);
    if ((str2 != null) && (!("android".equals(str1))))
    {
      paramArrayOfString[0] = "<manifest> specifies bad package name \"" + str1 + "\": " + str2;
      return null;
    }
    int j = -1;
    for (int k = 0; ; ++k)
    {
      if (k < paramAttributeSet.getAttributeCount())
      {
        if (!(paramAttributeSet.getAttributeName(k).equals("installLocation")))
          continue;
        j = paramAttributeSet.getAttributeIntValue(k, -1);
      }
      return new PackageLite(str1.intern(), j);
    }
  }

  private static String parsePackageName(XmlPullParser paramXmlPullParser, AttributeSet paramAttributeSet, int paramInt, String[] paramArrayOfString)
    throws IOException, XmlPullParserException
  {
    int i;
    do
      i = paramXmlPullParser.next();
    while ((i != 2) && (i != 1));
    if (i != 2)
    {
      paramArrayOfString[0] = "No start tag found";
      return null;
    }
    if (((paramInt & 0x2) == 0) || (!(paramXmlPullParser.getName().equals("manifest"))))
    {
      paramArrayOfString[0] = "No <manifest> tag";
      return null;
    }
    String str1 = paramAttributeSet.getAttributeValue(null, "package");
    if ((str1 == null) || (str1.length() == 0))
    {
      paramArrayOfString[0] = "<manifest> does not specify package";
      return null;
    }
    String str2 = validateName(str1, true);
    if ((str2 != null) && (!("android".equals(str1))))
    {
      paramArrayOfString[0] = "<manifest> specifies bad package name \"" + str1 + "\": " + str2;
      return null;
    }
    return str1.intern();
  }

  private Permission parsePermission(Package paramPackage, Resources paramResources, XmlPullParser paramXmlPullParser, AttributeSet paramAttributeSet, String[] paramArrayOfString)
    throws XmlPullParserException, IOException
  {
    Permission localPermission = new Permission(paramPackage);
    TypedArray localTypedArray = paramResources.obtainAttributes(paramAttributeSet, R.styleable.AndroidManifestPermission);
    if (!(parsePackageItemInfo(paramPackage, localPermission.info, paramArrayOfString, "<permission>", localTypedArray, 2, 0, 1, 0)))
    {
      localTypedArray.recycle();
      this.mParseError = -108;
      return null;
    }
    localPermission.info.group = localTypedArray.getNonResourceString(4);
    if (localPermission.info.group != null)
      localPermission.info.group = localPermission.info.group.intern();
    localPermission.info.descriptionRes = localTypedArray.getResourceId(5, 0);
    localPermission.info.protectionLevel = localTypedArray.getInt(3, 0);
    localTypedArray.recycle();
    if (localPermission.info.protectionLevel == -1)
    {
      paramArrayOfString[0] = "<permission> does not specify protectionLevel";
      this.mParseError = -108;
      return null;
    }
    if (!(parseAllMetaData(paramResources, paramXmlPullParser, paramAttributeSet, "<permission>", localPermission, paramArrayOfString)))
    {
      this.mParseError = -108;
      return null;
    }
    paramPackage.permissions.add(localPermission);
    return localPermission;
  }

  private PermissionGroup parsePermissionGroup(Package paramPackage, Resources paramResources, XmlPullParser paramXmlPullParser, AttributeSet paramAttributeSet, String[] paramArrayOfString)
    throws XmlPullParserException, IOException
  {
    PermissionGroup localPermissionGroup = new PermissionGroup(paramPackage);
    TypedArray localTypedArray = paramResources.obtainAttributes(paramAttributeSet, R.styleable.AndroidManifestPermissionGroup);
    if (!(parsePackageItemInfo(paramPackage, localPermissionGroup.info, paramArrayOfString, "<permission-group>", localTypedArray, 2, 0, 1, 0)))
    {
      localTypedArray.recycle();
      this.mParseError = -108;
      return null;
    }
    localPermissionGroup.info.descriptionRes = localTypedArray.getResourceId(3, 0);
    localTypedArray.recycle();
    if (!(parseAllMetaData(paramResources, paramXmlPullParser, paramAttributeSet, "<permission-group>", localPermissionGroup, paramArrayOfString)))
    {
      this.mParseError = -108;
      return null;
    }
    paramPackage.permissionGroups.add(localPermissionGroup);
    return localPermissionGroup;
  }

  private Permission parsePermissionTree(Package paramPackage, Resources paramResources, XmlPullParser paramXmlPullParser, AttributeSet paramAttributeSet, String[] paramArrayOfString)
    throws XmlPullParserException, IOException
  {
    Permission localPermission = new Permission(paramPackage);
    TypedArray localTypedArray = paramResources.obtainAttributes(paramAttributeSet, R.styleable.AndroidManifestPermissionTree);
    if (!(parsePackageItemInfo(paramPackage, localPermission.info, paramArrayOfString, "<permission-tree>", localTypedArray, 2, 0, 1, 0)))
    {
      localTypedArray.recycle();
      this.mParseError = -108;
      return null;
    }
    localTypedArray.recycle();
    int i = localPermission.info.name.indexOf(46);
    if (i > 0)
      i = localPermission.info.name.indexOf(46, i + 1);
    if (i < 0)
    {
      paramArrayOfString[0] = "<permission-tree> name has less than three segments: " + localPermission.info.name;
      this.mParseError = -108;
      return null;
    }
    localPermission.info.descriptionRes = 0;
    localPermission.info.protectionLevel = 0;
    localPermission.tree = true;
    if (!(parseAllMetaData(paramResources, paramXmlPullParser, paramAttributeSet, "<permission-tree>", localPermission, paramArrayOfString)))
    {
      this.mParseError = -108;
      return null;
    }
    paramPackage.permissions.add(localPermission);
    return localPermission;
  }

  private Provider parseProvider(Package paramPackage, Resources paramResources, XmlPullParser paramXmlPullParser, AttributeSet paramAttributeSet, int paramInt, String[] paramArrayOfString)
    throws XmlPullParserException, IOException
  {
    TypedArray localTypedArray = paramResources.obtainAttributes(paramAttributeSet, R.styleable.AndroidManifestProvider);
    if (this.mParseProviderArgs == null)
    {
      this.mParseProviderArgs = new ParseComponentArgs(paramPackage, paramArrayOfString, 2, 0, 1, 0, this.mSeparateProcesses, 8, 14, 6);
      this.mParseProviderArgs.tag = "<provider>";
    }
    this.mParseProviderArgs.sa = localTypedArray;
    this.mParseProviderArgs.flags = paramInt;
    Provider localProvider = new Provider(this.mParseProviderArgs, new ProviderInfo());
    if (paramArrayOfString[0] != null)
    {
      localTypedArray.recycle();
      localProvider = null;
    }
    do
    {
      label201: String str5;
      return localProvider;
      localProvider.info.exported = localTypedArray.getBoolean(7, true);
      String str1 = localTypedArray.getNonConfigurationString(10, 0);
      localProvider.info.isSyncable = localTypedArray.getBoolean(11, false);
      String str2 = localTypedArray.getNonConfigurationString(3, 0);
      String str3 = localTypedArray.getNonConfigurationString(4, 0);
      if (str3 == null)
        str3 = str2;
      if (str3 == null)
      {
        localProvider.info.readPermission = paramPackage.applicationInfo.permission;
        str5 = localTypedArray.getNonConfigurationString(5, 0);
        if (str5 == null)
          str5 = str2;
        if (str5 == null)
        {
          localProvider.info.writePermission = paramPackage.applicationInfo.permission;
          label239: localProvider.info.grantUriPermissions = localTypedArray.getBoolean(13, false);
          localProvider.info.multiprocess = localTypedArray.getBoolean(9, false);
          localProvider.info.initOrder = localTypedArray.getInt(12, 0);
          localTypedArray.recycle();
          if (((0x8000000 & paramPackage.applicationInfo.flags) == 0) || (localProvider.info.processName != paramPackage.packageName))
            break label412;
          paramArrayOfString[0] = "Heavy-weight applications can not have providers in main process";
          return null;
        }
      }
      else
      {
        ProviderInfo localProviderInfo1 = localProvider.info;
        if (str3.length() > 0);
        for (String str4 = str3.toString().intern(); ; str4 = null)
        {
          localProviderInfo1.readPermission = str4;
          break label201:
        }
        ProviderInfo localProviderInfo2 = localProvider.info;
        if (str5.length() > 0);
        for (String str6 = str5.toString().intern(); ; str6 = null)
        {
          localProviderInfo2.writePermission = str6;
          break label239:
        }
      }
      if (str1 == null)
      {
        label412: paramArrayOfString[0] = "<provider> does not incude authorities attribute";
        return null;
      }
      localProvider.info.authority = str1.intern();
    }
    while (parseProviderTags(paramResources, paramXmlPullParser, paramAttributeSet, localProvider, paramArrayOfString));
    return null;
  }

  private boolean parseProviderTags(Resources paramResources, XmlPullParser paramXmlPullParser, AttributeSet paramAttributeSet, Provider paramProvider, String[] paramArrayOfString)
    throws XmlPullParserException, IOException
  {
    int i = paramXmlPullParser.getDepth();
    while (true)
    {
      label8: int j = paramXmlPullParser.next();
      if ((j == 1) || ((j == 3) && (paramXmlPullParser.getDepth() <= i)))
        break;
      if ((j == 3) || (j == 4))
        continue;
      if (paramXmlPullParser.getName().equals("meta-data"))
      {
        Bundle localBundle = parseMetaData(paramResources, paramXmlPullParser, paramAttributeSet, paramProvider.metaData, paramArrayOfString);
        paramProvider.metaData = localBundle;
        if (localBundle == null);
        return false;
      }
      if (paramXmlPullParser.getName().equals("grant-uri-permission"))
      {
        TypedArray localTypedArray2 = paramResources.obtainAttributes(paramAttributeSet, R.styleable.AndroidManifestGrantUriPermission);
        String str7 = localTypedArray2.getNonConfigurationString(0, 0);
        PatternMatcher localPatternMatcher = null;
        if (str7 != null)
          localPatternMatcher = new PatternMatcher(str7, 0);
        String str8 = localTypedArray2.getNonConfigurationString(1, 0);
        if (str8 != null)
          localPatternMatcher = new PatternMatcher(str8, 1);
        String str9 = localTypedArray2.getNonConfigurationString(2, 0);
        if (str9 != null)
          localPatternMatcher = new PatternMatcher(str9, 2);
        localTypedArray2.recycle();
        if (localPatternMatcher != null)
        {
          if (paramProvider.info.uriPermissionPatterns == null)
          {
            paramProvider.info.uriPermissionPatterns = new PatternMatcher[1];
            paramProvider.info.uriPermissionPatterns[0] = localPatternMatcher;
          }
          while (true)
          {
            paramProvider.info.grantUriPermissions = true;
            XmlUtils.skipCurrentTag(paramXmlPullParser);
            break label8:
            int i1 = paramProvider.info.uriPermissionPatterns.length;
            PatternMatcher[] arrayOfPatternMatcher = new PatternMatcher[i1 + 1];
            System.arraycopy(paramProvider.info.uriPermissionPatterns, 0, arrayOfPatternMatcher, 0, i1);
            arrayOfPatternMatcher[i1] = localPatternMatcher;
            paramProvider.info.uriPermissionPatterns = arrayOfPatternMatcher;
          }
        }
        Log.w("PackageParser", "Unknown element under <path-permission>: " + paramXmlPullParser.getName() + " at " + this.mArchiveSourcePath + " " + paramXmlPullParser.getPositionDescription());
        XmlUtils.skipCurrentTag(paramXmlPullParser);
      }
      if (paramXmlPullParser.getName().equals("path-permission"))
      {
        TypedArray localTypedArray1 = paramResources.obtainAttributes(paramAttributeSet, R.styleable.AndroidManifestPathPermission);
        String str1 = localTypedArray1.getNonConfigurationString(0, 0);
        String str2 = localTypedArray1.getNonConfigurationString(1, 0);
        if (str2 == null)
          str2 = str1;
        String str3 = localTypedArray1.getNonConfigurationString(2, 0);
        if (str3 == null)
          str3 = str1;
        int k = 0;
        if (str2 != null)
        {
          str2 = str2.intern();
          k = 1;
        }
        if (str3 != null)
        {
          str3 = str3.intern();
          k = 1;
        }
        if (k == 0)
        {
          Log.w("PackageParser", "No readPermission or writePermssion for <path-permission>: " + paramXmlPullParser.getName() + " at " + this.mArchiveSourcePath + " " + paramXmlPullParser.getPositionDescription());
          XmlUtils.skipCurrentTag(paramXmlPullParser);
        }
        String str4 = localTypedArray1.getNonConfigurationString(3, 0);
        PathPermission localPathPermission = null;
        if (str4 != null)
          localPathPermission = new PathPermission(str4, 0, str2, str3);
        String str5 = localTypedArray1.getNonConfigurationString(4, 0);
        if (str5 != null)
          localPathPermission = new PathPermission(str5, 1, str2, str3);
        String str6 = localTypedArray1.getNonConfigurationString(5, 0);
        if (str6 != null)
          localPathPermission = new PathPermission(str6, 2, str2, str3);
        localTypedArray1.recycle();
        if (localPathPermission != null)
        {
          if (paramProvider.info.pathPermissions == null)
          {
            paramProvider.info.pathPermissions = new PathPermission[1];
            paramProvider.info.pathPermissions[0] = localPathPermission;
          }
          while (true)
          {
            XmlUtils.skipCurrentTag(paramXmlPullParser);
            break label8:
            int l = paramProvider.info.pathPermissions.length;
            PathPermission[] arrayOfPathPermission = new PathPermission[l + 1];
            System.arraycopy(paramProvider.info.pathPermissions, 0, arrayOfPathPermission, 0, l);
            arrayOfPathPermission[l] = localPathPermission;
            paramProvider.info.pathPermissions = arrayOfPathPermission;
          }
        }
        Log.w("PackageParser", "No path, pathPrefix, or pathPattern for <path-permission>: " + paramXmlPullParser.getName() + " at " + this.mArchiveSourcePath + " " + paramXmlPullParser.getPositionDescription());
        XmlUtils.skipCurrentTag(paramXmlPullParser);
      }
      Log.w("PackageParser", "Unknown element under <provider>: " + paramXmlPullParser.getName() + " at " + this.mArchiveSourcePath + " " + paramXmlPullParser.getPositionDescription());
      XmlUtils.skipCurrentTag(paramXmlPullParser);
    }
    return true;
  }

  private Service parseService(Package paramPackage, Resources paramResources, XmlPullParser paramXmlPullParser, AttributeSet paramAttributeSet, int paramInt, String[] paramArrayOfString)
    throws XmlPullParserException, IOException
  {
    boolean bool;
    TypedArray localTypedArray = paramResources.obtainAttributes(paramAttributeSet, R.styleable.AndroidManifestService);
    if (this.mParseServiceArgs == null)
    {
      this.mParseServiceArgs = new ParseComponentArgs(paramPackage, paramArrayOfString, 2, 0, 1, 0, this.mSeparateProcesses, 6, 7, 4);
      this.mParseServiceArgs.tag = "<service>";
    }
    this.mParseServiceArgs.sa = localTypedArray;
    this.mParseServiceArgs.flags = paramInt;
    Service localService = new Service(this.mParseServiceArgs, new ServiceInfo());
    if (paramArrayOfString[0] != null)
    {
      localTypedArray.recycle();
      localService = null;
    }
    do
    {
      return localService;
      bool = localTypedArray.hasValue(5);
      if (bool)
        localService.info.exported = localTypedArray.getBoolean(5, false);
      String str1 = localTypedArray.getNonConfigurationString(3, 0);
      if (str1 == null)
      {
        localService.info.permission = paramPackage.applicationInfo.permission;
        label168: localTypedArray.recycle();
        if (((0x8000000 & paramPackage.applicationInfo.flags) != 0) && (localService.info.processName == paramPackage.packageName))
        {
          paramArrayOfString[0] = "Heavy-weight applications can not have services in main process";
          return null;
        }
      }
      else
      {
        ServiceInfo localServiceInfo1 = localService.info;
        if (str1.length() > 0);
        for (String str2 = str1.toString().intern(); ; str2 = null)
        {
          localServiceInfo1.permission = str2;
          break label168:
        }
      }
      int i = paramXmlPullParser.getDepth();
      while (true)
      {
        int j = paramXmlPullParser.next();
        if ((j == 1) || ((j == 3) && (paramXmlPullParser.getDepth() <= i)))
          break;
        if ((j == 3) || (j == 4))
          continue;
        if (paramXmlPullParser.getName().equals("intent-filter"))
        {
          ServiceIntentInfo localServiceIntentInfo = new ServiceIntentInfo(localService);
          if (!(parseIntent(paramResources, paramXmlPullParser, paramAttributeSet, paramInt, localServiceIntentInfo, paramArrayOfString, false)))
            return null;
          localService.intents.add(localServiceIntentInfo);
        }
        if (paramXmlPullParser.getName().equals("meta-data"))
        {
          Bundle localBundle = parseMetaData(paramResources, paramXmlPullParser, paramAttributeSet, localService.metaData, paramArrayOfString);
          localService.metaData = localBundle;
          if (localBundle == null);
          return null;
        }
        Log.w("PackageParser", "Unknown element under <service>: " + paramXmlPullParser.getName() + " at " + this.mArchiveSourcePath + " " + paramXmlPullParser.getPositionDescription());
        XmlUtils.skipCurrentTag(paramXmlPullParser);
      }
    }
    while (bool);
    ServiceInfo localServiceInfo2 = localService.info;
    if (localService.intents.size() > 0);
    for (int k = 1; ; k = 0)
    {
      localServiceInfo2.exported = k;
      return localService;
    }
  }

  public static void setCompatibilityModeEnabled(boolean paramBoolean)
  {
    sCompatibilityModeEnabled = paramBoolean;
  }

  public static Signature stringToSignature(String paramString)
  {
    int i = paramString.length();
    byte[] arrayOfByte = new byte[i];
    for (int j = 0; j < i; ++j)
      arrayOfByte[j] = (byte)paramString.charAt(j);
    return new Signature(arrayOfByte);
  }

  private static String validateName(String paramString, boolean paramBoolean)
  {
    int i = paramString.length();
    int j = 0;
    int k = 1;
    int l = 0;
    if (l < i)
    {
      label13: char c = paramString.charAt(l);
      if (((c >= 'a') && (c <= 'z')) || ((c >= 'A') && (c <= 'Z')));
      for (k = 0; ; k = 1)
      {
        do
        {
          ++l;
          break label13:
        }
        while ((k == 0) && ((((c >= '0') && (c <= '9')) || (c == '_'))));
        if (c != '.')
          break;
        j = 1;
      }
      return "bad character '" + c + "'";
    }
    if ((j != 0) || (!(paramBoolean)))
      return null;
    return "must have at least one '.' separator";
  }

  // ERROR //
  public boolean collectCertificates(Package paramPackage, int paramInt)
  {
    // Byte code:
    //   0: aload_1
    //   1: aconst_null
    //   2: putfield 413	android/content/pm/PackageParser$Package:mSignatures	[Landroid/content/pm/Signature;
    //   5: getstatic 90	android/content/pm/PackageParser:mSync	Ljava/lang/Object;
    //   8: astore_3
    //   9: aload_3
    //   10: monitorenter
    //   11: getstatic 1329	android/content/pm/PackageParser:mReadBuffer	Ljava/lang/ref/WeakReference;
    //   14: astore 5
    //   16: aconst_null
    //   17: astore 6
    //   19: aload 5
    //   21: ifnull +17 -> 38
    //   24: aconst_null
    //   25: putstatic 1329	android/content/pm/PackageParser:mReadBuffer	Ljava/lang/ref/WeakReference;
    //   28: aload 5
    //   30: invokevirtual 1334	java/lang/ref/WeakReference:get	()Ljava/lang/Object;
    //   33: checkcast 1336	[B
    //   36: astore 6
    //   38: aload 6
    //   40: ifnonnull +21 -> 61
    //   43: sipush 8192
    //   46: newarray byte
    //   48: astore 6
    //   50: new 1331	java/lang/ref/WeakReference
    //   53: dup
    //   54: aload 6
    //   56: invokespecial 1339	java/lang/ref/WeakReference:<init>	(Ljava/lang/Object;)V
    //   59: astore 5
    //   61: aload_3
    //   62: monitorexit
    //   63: new 481	java/util/jar/JarFile
    //   66: dup
    //   67: aload_0
    //   68: getfield 97	android/content/pm/PackageParser:mArchiveSourcePath	Ljava/lang/String;
    //   71: invokespecial 1340	java/util/jar/JarFile:<init>	(Ljava/lang/String;)V
    //   74: astore 7
    //   76: aconst_null
    //   77: astore 8
    //   79: iload_2
    //   80: iconst_1
    //   81: iand
    //   82: ifeq +99 -> 181
    //   85: aload 7
    //   87: ldc_w 1134
    //   90: invokevirtual 1344	java/util/jar/JarFile:getJarEntry	(Ljava/lang/String;)Ljava/util/jar/JarEntry;
    //   93: astore 15
    //   95: aload_0
    //   96: aload 7
    //   98: aload 15
    //   100: aload 6
    //   102: invokespecial 1346	android/content/pm/PackageParser:loadCertificates	(Ljava/util/jar/JarFile;Ljava/util/jar/JarEntry;[B)[Ljava/security/cert/Certificate;
    //   105: astore 8
    //   107: aload 8
    //   109: ifnonnull +331 -> 440
    //   112: ldc 35
    //   114: new 115	java/lang/StringBuilder
    //   117: dup
    //   118: invokespecial 116	java/lang/StringBuilder:<init>	()V
    //   121: ldc_w 1348
    //   124: invokevirtual 122	java/lang/StringBuilder:append	(Ljava/lang/String;)Ljava/lang/StringBuilder;
    //   127: aload_1
    //   128: getfield 261	android/content/pm/PackageParser$Package:packageName	Ljava/lang/String;
    //   131: invokevirtual 122	java/lang/StringBuilder:append	(Ljava/lang/String;)Ljava/lang/StringBuilder;
    //   134: ldc_w 1350
    //   137: invokevirtual 122	java/lang/StringBuilder:append	(Ljava/lang/String;)Ljava/lang/StringBuilder;
    //   140: aload 15
    //   142: invokevirtual 508	java/util/jar/JarEntry:getName	()Ljava/lang/String;
    //   145: invokevirtual 122	java/lang/StringBuilder:append	(Ljava/lang/String;)Ljava/lang/StringBuilder;
    //   148: ldc_w 1352
    //   151: invokevirtual 122	java/lang/StringBuilder:append	(Ljava/lang/String;)Ljava/lang/StringBuilder;
    //   154: invokevirtual 126	java/lang/StringBuilder:toString	()Ljava/lang/String;
    //   157: invokestatic 1148	android/util/Log:e	(Ljava/lang/String;Ljava/lang/String;)I
    //   160: pop
    //   161: aload 7
    //   163: invokevirtual 1353	java/util/jar/JarFile:close	()V
    //   166: aload_0
    //   167: bipush 153
    //   169: putfield 95	android/content/pm/PackageParser:mParseError	I
    //   172: iconst_0
    //   173: ireturn
    //   174: astore 4
    //   176: aload_3
    //   177: monitorexit
    //   178: aload 4
    //   180: athrow
    //   181: aload 7
    //   183: invokevirtual 1357	java/util/jar/JarFile:entries	()Ljava/util/Enumeration;
    //   186: astore 22
    //   188: aload 22
    //   190: invokeinterface 1363 1 0
    //   195: ifeq +245 -> 440
    //   198: aload 22
    //   200: invokeinterface 1366 1 0
    //   205: checkcast 499	java/util/jar/JarEntry
    //   208: astore 23
    //   210: aload 23
    //   212: invokevirtual 1369	java/util/jar/JarEntry:isDirectory	()Z
    //   215: ifne -27 -> 188
    //   218: aload 23
    //   220: invokevirtual 508	java/util/jar/JarEntry:getName	()Ljava/lang/String;
    //   223: ldc_w 1371
    //   226: invokevirtual 1374	java/lang/String:startsWith	(Ljava/lang/String;)Z
    //   229: ifne -41 -> 188
    //   232: aload_0
    //   233: aload 7
    //   235: aload 23
    //   237: aload 6
    //   239: invokespecial 1346	android/content/pm/PackageParser:loadCertificates	(Ljava/util/jar/JarFile;Ljava/util/jar/JarEntry;[B)[Ljava/security/cert/Certificate;
    //   242: astore 24
    //   244: aload 24
    //   246: ifnonnull +455 -> 701
    //   249: ldc 35
    //   251: new 115	java/lang/StringBuilder
    //   254: dup
    //   255: invokespecial 116	java/lang/StringBuilder:<init>	()V
    //   258: ldc_w 1348
    //   261: invokevirtual 122	java/lang/StringBuilder:append	(Ljava/lang/String;)Ljava/lang/StringBuilder;
    //   264: aload_1
    //   265: getfield 261	android/content/pm/PackageParser$Package:packageName	Ljava/lang/String;
    //   268: invokevirtual 122	java/lang/StringBuilder:append	(Ljava/lang/String;)Ljava/lang/StringBuilder;
    //   271: ldc_w 1350
    //   274: invokevirtual 122	java/lang/StringBuilder:append	(Ljava/lang/String;)Ljava/lang/StringBuilder;
    //   277: aload 23
    //   279: invokevirtual 508	java/util/jar/JarEntry:getName	()Ljava/lang/String;
    //   282: invokevirtual 122	java/lang/StringBuilder:append	(Ljava/lang/String;)Ljava/lang/StringBuilder;
    //   285: ldc_w 1352
    //   288: invokevirtual 122	java/lang/StringBuilder:append	(Ljava/lang/String;)Ljava/lang/StringBuilder;
    //   291: invokevirtual 126	java/lang/StringBuilder:toString	()Ljava/lang/String;
    //   294: invokestatic 1148	android/util/Log:e	(Ljava/lang/String;Ljava/lang/String;)I
    //   297: pop
    //   298: aload 7
    //   300: invokevirtual 1353	java/util/jar/JarFile:close	()V
    //   303: aload_0
    //   304: bipush 153
    //   306: putfield 95	android/content/pm/PackageParser:mParseError	I
    //   309: iconst_0
    //   310: ireturn
    //   311: iload 26
    //   313: aload 8
    //   315: arraylength
    //   316: if_icmpge -128 -> 188
    //   319: iconst_0
    //   320: istore 27
    //   322: aload 24
    //   324: arraylength
    //   325: istore 28
    //   327: iconst_0
    //   328: istore 29
    //   330: iload 27
    //   332: iload 28
    //   334: if_icmpge +30 -> 364
    //   337: aload 8
    //   339: iload 26
    //   341: aaload
    //   342: ifnull +377 -> 719
    //   345: aload 8
    //   347: iload 26
    //   349: aaload
    //   350: aload 24
    //   352: iload 27
    //   354: aaload
    //   355: invokevirtual 1377	java/security/cert/Certificate:equals	(Ljava/lang/Object;)Z
    //   358: ifeq +361 -> 719
    //   361: iconst_1
    //   362: istore 29
    //   364: iload 29
    //   366: ifeq +12 -> 378
    //   369: aload 8
    //   371: arraylength
    //   372: aload 24
    //   374: arraylength
    //   375: if_icmpeq +350 -> 725
    //   378: ldc 35
    //   380: new 115	java/lang/StringBuilder
    //   383: dup
    //   384: invokespecial 116	java/lang/StringBuilder:<init>	()V
    //   387: ldc_w 1348
    //   390: invokevirtual 122	java/lang/StringBuilder:append	(Ljava/lang/String;)Ljava/lang/StringBuilder;
    //   393: aload_1
    //   394: getfield 261	android/content/pm/PackageParser$Package:packageName	Ljava/lang/String;
    //   397: invokevirtual 122	java/lang/StringBuilder:append	(Ljava/lang/String;)Ljava/lang/StringBuilder;
    //   400: ldc_w 1379
    //   403: invokevirtual 122	java/lang/StringBuilder:append	(Ljava/lang/String;)Ljava/lang/StringBuilder;
    //   406: aload 23
    //   408: invokevirtual 508	java/util/jar/JarEntry:getName	()Ljava/lang/String;
    //   411: invokevirtual 122	java/lang/StringBuilder:append	(Ljava/lang/String;)Ljava/lang/StringBuilder;
    //   414: ldc_w 1352
    //   417: invokevirtual 122	java/lang/StringBuilder:append	(Ljava/lang/String;)Ljava/lang/StringBuilder;
    //   420: invokevirtual 126	java/lang/StringBuilder:toString	()Ljava/lang/String;
    //   423: invokestatic 1148	android/util/Log:e	(Ljava/lang/String;Ljava/lang/String;)I
    //   426: pop
    //   427: aload 7
    //   429: invokevirtual 1353	java/util/jar/JarFile:close	()V
    //   432: aload_0
    //   433: bipush 152
    //   435: putfield 95	android/content/pm/PackageParser:mParseError	I
    //   438: iconst_0
    //   439: ireturn
    //   440: aload 7
    //   442: invokevirtual 1353	java/util/jar/JarFile:close	()V
    //   445: getstatic 90	android/content/pm/PackageParser:mSync	Ljava/lang/Object;
    //   448: astore 17
    //   450: aload 17
    //   452: monitorenter
    //   453: aload 5
    //   455: putstatic 1329	android/content/pm/PackageParser:mReadBuffer	Ljava/lang/ref/WeakReference;
    //   458: aload 17
    //   460: monitorexit
    //   461: aload 8
    //   463: ifnull +111 -> 574
    //   466: aload 8
    //   468: arraylength
    //   469: ifle +105 -> 574
    //   472: aload 8
    //   474: arraylength
    //   475: istore 20
    //   477: aload_1
    //   478: aload 8
    //   480: arraylength
    //   481: anewarray 415	android/content/pm/Signature
    //   484: putfield 413	android/content/pm/PackageParser$Package:mSignatures	[Landroid/content/pm/Signature;
    //   487: iconst_0
    //   488: istore 21
    //   490: iload 21
    //   492: iload 20
    //   494: if_icmpge +205 -> 699
    //   497: aload_1
    //   498: getfield 413	android/content/pm/PackageParser$Package:mSignatures	[Landroid/content/pm/Signature;
    //   501: iload 21
    //   503: new 415	android/content/pm/Signature
    //   506: dup
    //   507: aload 8
    //   509: iload 21
    //   511: aaload
    //   512: invokevirtual 1383	java/security/cert/Certificate:getEncoded	()[B
    //   515: invokespecial 1317	android/content/pm/Signature:<init>	([B)V
    //   518: aastore
    //   519: iinc 21 1
    //   522: goto -32 -> 490
    //   525: astore 18
    //   527: aload 17
    //   529: monitorexit
    //   530: aload 18
    //   532: athrow
    //   533: astore 13
    //   535: ldc 35
    //   537: new 115	java/lang/StringBuilder
    //   540: dup
    //   541: invokespecial 116	java/lang/StringBuilder:<init>	()V
    //   544: ldc_w 505
    //   547: invokevirtual 122	java/lang/StringBuilder:append	(Ljava/lang/String;)Ljava/lang/StringBuilder;
    //   550: aload_0
    //   551: getfield 97	android/content/pm/PackageParser:mArchiveSourcePath	Ljava/lang/String;
    //   554: invokevirtual 122	java/lang/StringBuilder:append	(Ljava/lang/String;)Ljava/lang/StringBuilder;
    //   557: invokevirtual 126	java/lang/StringBuilder:toString	()Ljava/lang/String;
    //   560: aload 13
    //   562: invokestatic 517	android/util/Log:w	(Ljava/lang/String;Ljava/lang/String;Ljava/lang/Throwable;)I
    //   565: pop
    //   566: aload_0
    //   567: bipush 151
    //   569: putfield 95	android/content/pm/PackageParser:mParseError	I
    //   572: iconst_0
    //   573: ireturn
    //   574: ldc 35
    //   576: new 115	java/lang/StringBuilder
    //   579: dup
    //   580: invokespecial 116	java/lang/StringBuilder:<init>	()V
    //   583: ldc_w 1348
    //   586: invokevirtual 122	java/lang/StringBuilder:append	(Ljava/lang/String;)Ljava/lang/StringBuilder;
    //   589: aload_1
    //   590: getfield 261	android/content/pm/PackageParser$Package:packageName	Ljava/lang/String;
    //   593: invokevirtual 122	java/lang/StringBuilder:append	(Ljava/lang/String;)Ljava/lang/StringBuilder;
    //   596: ldc_w 1385
    //   599: invokevirtual 122	java/lang/StringBuilder:append	(Ljava/lang/String;)Ljava/lang/StringBuilder;
    //   602: invokevirtual 126	java/lang/StringBuilder:toString	()Ljava/lang/String;
    //   605: invokestatic 1148	android/util/Log:e	(Ljava/lang/String;Ljava/lang/String;)I
    //   608: pop
    //   609: aload_0
    //   610: bipush 153
    //   612: putfield 95	android/content/pm/PackageParser:mParseError	I
    //   615: iconst_0
    //   616: ireturn
    //   617: astore 11
    //   619: ldc 35
    //   621: new 115	java/lang/StringBuilder
    //   624: dup
    //   625: invokespecial 116	java/lang/StringBuilder:<init>	()V
    //   628: ldc_w 505
    //   631: invokevirtual 122	java/lang/StringBuilder:append	(Ljava/lang/String;)Ljava/lang/StringBuilder;
    //   634: aload_0
    //   635: getfield 97	android/content/pm/PackageParser:mArchiveSourcePath	Ljava/lang/String;
    //   638: invokevirtual 122	java/lang/StringBuilder:append	(Ljava/lang/String;)Ljava/lang/StringBuilder;
    //   641: invokevirtual 126	java/lang/StringBuilder:toString	()Ljava/lang/String;
    //   644: aload 11
    //   646: invokestatic 517	android/util/Log:w	(Ljava/lang/String;Ljava/lang/String;Ljava/lang/Throwable;)I
    //   649: pop
    //   650: aload_0
    //   651: bipush 151
    //   653: putfield 95	android/content/pm/PackageParser:mParseError	I
    //   656: iconst_0
    //   657: ireturn
    //   658: astore 9
    //   660: ldc 35
    //   662: new 115	java/lang/StringBuilder
    //   665: dup
    //   666: invokespecial 116	java/lang/StringBuilder:<init>	()V
    //   669: ldc_w 505
    //   672: invokevirtual 122	java/lang/StringBuilder:append	(Ljava/lang/String;)Ljava/lang/StringBuilder;
    //   675: aload_0
    //   676: getfield 97	android/content/pm/PackageParser:mArchiveSourcePath	Ljava/lang/String;
    //   679: invokevirtual 122	java/lang/StringBuilder:append	(Ljava/lang/String;)Ljava/lang/StringBuilder;
    //   682: invokevirtual 126	java/lang/StringBuilder:toString	()Ljava/lang/String;
    //   685: aload 9
    //   687: invokestatic 517	android/util/Log:w	(Ljava/lang/String;Ljava/lang/String;Ljava/lang/Throwable;)I
    //   690: pop
    //   691: aload_0
    //   692: bipush 154
    //   694: putfield 95	android/content/pm/PackageParser:mParseError	I
    //   697: iconst_0
    //   698: ireturn
    //   699: iconst_1
    //   700: ireturn
    //   701: aload 8
    //   703: ifnonnull +10 -> 713
    //   706: aload 24
    //   708: astore 8
    //   710: goto -522 -> 188
    //   713: iconst_0
    //   714: istore 26
    //   716: goto -405 -> 311
    //   719: iinc 27 1
    //   722: goto -400 -> 322
    //   725: iinc 26 1
    //   728: goto -417 -> 311
    //
    // Exception table:
    //   from	to	target	type
    //   11	16	174	finally
    //   24	38	174	finally
    //   43	61	174	finally
    //   61	63	174	finally
    //   176	178	174	finally
    //   453	461	525	finally
    //   527	530	525	finally
    //   63	76	533	java/security/cert/CertificateEncodingException
    //   85	107	533	java/security/cert/CertificateEncodingException
    //   112	172	533	java/security/cert/CertificateEncodingException
    //   181	188	533	java/security/cert/CertificateEncodingException
    //   188	244	533	java/security/cert/CertificateEncodingException
    //   249	309	533	java/security/cert/CertificateEncodingException
    //   311	319	533	java/security/cert/CertificateEncodingException
    //   322	327	533	java/security/cert/CertificateEncodingException
    //   337	361	533	java/security/cert/CertificateEncodingException
    //   369	378	533	java/security/cert/CertificateEncodingException
    //   378	438	533	java/security/cert/CertificateEncodingException
    //   440	453	533	java/security/cert/CertificateEncodingException
    //   466	487	533	java/security/cert/CertificateEncodingException
    //   497	519	533	java/security/cert/CertificateEncodingException
    //   530	533	533	java/security/cert/CertificateEncodingException
    //   574	615	533	java/security/cert/CertificateEncodingException
    //   63	76	617	IOException
    //   85	107	617	IOException
    //   112	172	617	IOException
    //   181	188	617	IOException
    //   188	244	617	IOException
    //   249	309	617	IOException
    //   311	319	617	IOException
    //   322	327	617	IOException
    //   337	361	617	IOException
    //   369	378	617	IOException
    //   378	438	617	IOException
    //   440	453	617	IOException
    //   466	487	617	IOException
    //   497	519	617	IOException
    //   530	533	617	IOException
    //   574	615	617	IOException
    //   63	76	658	java/lang/RuntimeException
    //   85	107	658	java/lang/RuntimeException
    //   112	172	658	java/lang/RuntimeException
    //   181	188	658	java/lang/RuntimeException
    //   188	244	658	java/lang/RuntimeException
    //   249	309	658	java/lang/RuntimeException
    //   311	319	658	java/lang/RuntimeException
    //   322	327	658	java/lang/RuntimeException
    //   337	361	658	java/lang/RuntimeException
    //   369	378	658	java/lang/RuntimeException
    //   378	438	658	java/lang/RuntimeException
    //   440	453	658	java/lang/RuntimeException
    //   466	487	658	java/lang/RuntimeException
    //   497	519	658	java/lang/RuntimeException
    //   530	533	658	java/lang/RuntimeException
    //   574	615	658	java/lang/RuntimeException
  }

  public int getParseError()
  {
    return this.mParseError;
  }

  public Package parsePackage(File paramFile, String paramString, DisplayMetrics paramDisplayMetrics, int paramInt)
  {
    AssetManager localAssetManager1;
    this.mParseError = 1;
    this.mArchiveSourcePath = paramFile.getPath();
    if (!(paramFile.isFile()))
    {
      Log.w("PackageParser", "Skipping dir: " + this.mArchiveSourcePath);
      this.mParseError = -100;
      return null;
    }
    if ((!(isPackageFilename(paramFile.getName()))) && ((paramInt & 0x4) != 0))
    {
      if ((paramInt & 0x1) == 0)
        Log.w("PackageParser", "Skipping non-package file: " + this.mArchiveSourcePath);
      this.mParseError = -100;
      return null;
    }
    if ((paramInt & 0x2) != 0)
      Log.d("PackageParser", "Scanning package: " + this.mArchiveSourcePath);
    int i = 1;
    try
    {
      localAssetManager1 = new AssetManager();
    }
    catch (Exception localException2)
    {
      AssetManager localAssetManager2;
      XmlResourceParser localXmlResourceParser1;
      try
      {
        int j = localAssetManager1.addAssetPath(this.mArchiveSourcePath);
        if (j != 0)
        {
          XmlResourceParser localXmlResourceParser2 = localAssetManager1.openXmlResourceParser(j, "AndroidManifest.xml");
          localXmlResourceParser1 = localXmlResourceParser2;
          i = 0;
          localAssetManager2 = localAssetManager1;
          label205: if (i == 0)
            break label306;
          if (localAssetManager2 != null)
            localAssetManager2.close();
          this.mParseError = -101;
          return null;
        }
        Log.w("PackageParser", "Failed adding asset path:" + this.mArchiveSourcePath);
        label410: label306: label465: label342: label364: localXmlResourceParser1 = null;
      }
      catch (Exception localException2)
      {
        for (localAssetManager2 = localAssetManager1; ; localAssetManager2 = null)
        {
          Package localPackage1;
          Log.w("PackageParser", "Unable to read AndroidManifest.xml of " + this.mArchiveSourcePath, localException1);
          localXmlResourceParser1 = null;
          break label205:
          String[] arrayOfString = new String[1];
          Object localObject = null;
          try
          {
            Package localPackage2 = parsePackage(new Resources(localAssetManager2, paramDisplayMetrics, null), localXmlResourceParser1, paramInt, arrayOfString);
            localPackage1 = localPackage2;
            if (localPackage1 != null)
              break label465;
            if (localObject == null)
              break label410;
            Log.w("PackageParser", this.mArchiveSourcePath, (Throwable)localObject);
            localXmlResourceParser1.close();
            localAssetManager2.close();
            if (this.mParseError == 1)
              this.mParseError = -108;
            return null;
          }
          catch (Exception localException3)
          {
            localObject = localException3;
            this.mParseError = -102;
            localPackage1 = null;
            break label342:
            Log.w("PackageParser", this.mArchiveSourcePath + " (at " + localXmlResourceParser1.getPositionDescription() + "): " + arrayOfString[0]);
            break label364:
            localXmlResourceParser1.close();
            localAssetManager2.close();
            localPackage1.mPath = paramString;
            localPackage1.mScanPath = this.mArchiveSourcePath;
            localPackage1.mSignatures = null;
            return localPackage1;
          }
          localException2 = localException2;
        }
      }
    }
  }

  public void setSeparateProcesses(String[] paramArrayOfString)
  {
    this.mSeparateProcesses = paramArrayOfString;
  }

  public static final class Activity extends PackageParser.Component<PackageParser.ActivityIntentInfo>
  {
    public final ActivityInfo info;

    public Activity(PackageParser.ParseComponentArgs paramParseComponentArgs, ActivityInfo paramActivityInfo)
    {
      super(paramParseComponentArgs, paramActivityInfo);
      this.info = paramActivityInfo;
      this.info.applicationInfo = paramParseComponentArgs.owner.applicationInfo;
    }

    public void setPackageName(String paramString)
    {
      super.setPackageName(paramString);
      this.info.packageName = paramString;
    }

    public String toString()
    {
      return "Activity{" + Integer.toHexString(System.identityHashCode(this)) + " " + getComponentShortName() + "}";
    }
  }

  public static final class ActivityIntentInfo extends PackageParser.IntentInfo
  {
    public final PackageParser.Activity activity;

    public ActivityIntentInfo(PackageParser.Activity paramActivity)
    {
      this.activity = paramActivity;
    }

    public String toString()
    {
      return "ActivityIntentInfo{" + Integer.toHexString(System.identityHashCode(this)) + " " + this.activity.info.name + "}";
    }
  }

  public static class Component<II extends PackageParser.IntentInfo>
  {
    public final String className;
    ComponentName componentName;
    String componentShortName;
    public final ArrayList<II> intents;
    public Bundle metaData;
    public final PackageParser.Package owner;

    public Component(Component<II> paramComponent)
    {
      this.owner = paramComponent.owner;
      this.intents = paramComponent.intents;
      this.className = paramComponent.className;
      this.componentName = paramComponent.componentName;
      this.componentShortName = paramComponent.componentShortName;
    }

    public Component(PackageParser.Package paramPackage)
    {
      this.owner = paramPackage;
      this.intents = null;
      this.className = null;
    }

    public Component(PackageParser.ParseComponentArgs paramParseComponentArgs, ComponentInfo paramComponentInfo)
    {
      this(paramParseComponentArgs, paramComponentInfo);
      if (paramParseComponentArgs.outError[0] != null)
        return;
      if (paramParseComponentArgs.processRes != 0)
        if (this.owner.applicationInfo.targetSdkVersion < 8)
          break label131;
      for (String str = paramParseComponentArgs.sa.getNonConfigurationString(paramParseComponentArgs.processRes, 0); ; str = paramParseComponentArgs.sa.getNonResourceString(paramParseComponentArgs.processRes))
      {
        paramComponentInfo.processName = PackageParser.access$100(this.owner.applicationInfo.packageName, this.owner.applicationInfo.processName, str, paramParseComponentArgs.flags, paramParseComponentArgs.sepProcesses, paramParseComponentArgs.outError);
        if (paramParseComponentArgs.descriptionRes != 0)
          paramComponentInfo.descriptionRes = paramParseComponentArgs.sa.getResourceId(paramParseComponentArgs.descriptionRes, 0);
        paramComponentInfo.enabled = paramParseComponentArgs.sa.getBoolean(paramParseComponentArgs.enabledRes, true);
        label131: return;
      }
    }

    public Component(PackageParser.ParsePackageItemArgs paramParsePackageItemArgs, PackageItemInfo paramPackageItemInfo)
    {
      this.owner = paramParsePackageItemArgs.owner;
      this.intents = new ArrayList(0);
      String str = paramParsePackageItemArgs.sa.getNonConfigurationString(paramParsePackageItemArgs.nameRes, 0);
      if (str == null)
      {
        this.className = null;
        paramParsePackageItemArgs.outError[0] = paramParsePackageItemArgs.tag + " does not specify android:name";
        return;
      }
      paramPackageItemInfo.name = PackageParser.access$000(this.owner.applicationInfo.packageName, str, paramParsePackageItemArgs.outError);
      if (paramPackageItemInfo.name == null)
      {
        this.className = null;
        paramParsePackageItemArgs.outError[0] = paramParsePackageItemArgs.tag + " does not have valid android:name";
        return;
      }
      this.className = paramPackageItemInfo.name;
      int i = paramParsePackageItemArgs.sa.getResourceId(paramParsePackageItemArgs.iconRes, 0);
      if (i != 0)
      {
        paramPackageItemInfo.icon = i;
        paramPackageItemInfo.nonLocalizedLabel = null;
      }
      TypedValue localTypedValue = paramParsePackageItemArgs.sa.peekValue(paramParsePackageItemArgs.labelRes);
      if (localTypedValue != null)
      {
        int j = localTypedValue.resourceId;
        paramPackageItemInfo.labelRes = j;
        if (j == 0)
          paramPackageItemInfo.nonLocalizedLabel = localTypedValue.coerceToString();
      }
      paramPackageItemInfo.packageName = this.owner.packageName;
    }

    public ComponentName getComponentName()
    {
      if (this.componentName != null)
        return this.componentName;
      if (this.className != null)
        this.componentName = new ComponentName(this.owner.applicationInfo.packageName, this.className);
      return this.componentName;
    }

    public String getComponentShortName()
    {
      if (this.componentShortName != null)
        return this.componentShortName;
      ComponentName localComponentName = getComponentName();
      if (localComponentName != null)
        this.componentShortName = localComponentName.flattenToShortString();
      return this.componentShortName;
    }

    public void setPackageName(String paramString)
    {
      this.componentName = null;
      this.componentShortName = null;
    }
  }

  public static final class Instrumentation extends PackageParser.Component
  {
    public final InstrumentationInfo info;

    public Instrumentation(PackageParser.ParsePackageItemArgs paramParsePackageItemArgs, InstrumentationInfo paramInstrumentationInfo)
    {
      super(paramParsePackageItemArgs, paramInstrumentationInfo);
      this.info = paramInstrumentationInfo;
    }

    public void setPackageName(String paramString)
    {
      super.setPackageName(paramString);
      this.info.packageName = paramString;
    }

    public String toString()
    {
      return "Instrumentation{" + Integer.toHexString(System.identityHashCode(this)) + " " + getComponentShortName() + "}";
    }
  }

  public static class IntentInfo extends IntentFilter
  {
    public boolean hasDefault;
    public int icon;
    public int labelRes;
    public int logo;
    public CharSequence nonLocalizedLabel;
  }

  public static class NewPermissionInfo
  {
    public final int fileVersion;
    public final String name;
    public final int sdkVersion;

    public NewPermissionInfo(String paramString, int paramInt1, int paramInt2)
    {
      this.name = paramString;
      this.sdkVersion = paramInt1;
      this.fileVersion = paramInt2;
    }
  }

  public static final class Package
  {
    public final ArrayList<PackageParser.Activity> activities = new ArrayList(0);
    public final ApplicationInfo applicationInfo = new ApplicationInfo();
    public final ArrayList<ConfigurationInfo> configPreferences = new ArrayList();
    public int installLocation;
    public final ArrayList<PackageParser.Instrumentation> instrumentation = new ArrayList(0);
    public ArrayList<String> mAdoptPermissions = null;
    public Bundle mAppMetaData = null;
    public boolean mDidDexOpt;
    public Object mExtras;
    public boolean mOperationPending;
    public ArrayList<String> mOriginalPackages = null;
    public String mPath;
    public int mPreferredOrder = 0;
    public String mRealPackage = null;
    public String mScanPath;
    public int mSetEnabled = 0;
    public String mSharedUserId;
    public int mSharedUserLabel;
    public Signature[] mSignatures;
    public int mVersionCode;
    public String mVersionName;
    public String packageName;
    public final ArrayList<PackageParser.PermissionGroup> permissionGroups = new ArrayList(0);
    public final ArrayList<PackageParser.Permission> permissions = new ArrayList(0);
    public ArrayList<String> protectedBroadcasts;
    public final ArrayList<PackageParser.Provider> providers = new ArrayList(0);
    public final ArrayList<PackageParser.Activity> receivers = new ArrayList(0);
    public ArrayList<FeatureInfo> reqFeatures = null;
    public final ArrayList<String> requestedPermissions = new ArrayList();
    public final ArrayList<PackageParser.Service> services = new ArrayList(0);
    public ArrayList<String> usesLibraries = null;
    public String[] usesLibraryFiles = null;
    public ArrayList<String> usesOptionalLibraries = null;

    public Package(String paramString)
    {
      this.packageName = paramString;
      this.applicationInfo.packageName = paramString;
      this.applicationInfo.uid = -1;
    }

    public void setPackageName(String paramString)
    {
      this.packageName = paramString;
      this.applicationInfo.packageName = paramString;
      for (int i = -1 + this.permissions.size(); i >= 0; --i)
        ((PackageParser.Permission)this.permissions.get(i)).setPackageName(paramString);
      for (int j = -1 + this.permissionGroups.size(); j >= 0; --j)
        ((PackageParser.PermissionGroup)this.permissionGroups.get(j)).setPackageName(paramString);
      for (int k = -1 + this.activities.size(); k >= 0; --k)
        ((PackageParser.Activity)this.activities.get(k)).setPackageName(paramString);
      for (int l = -1 + this.receivers.size(); l >= 0; --l)
        ((PackageParser.Activity)this.receivers.get(l)).setPackageName(paramString);
      for (int i1 = -1 + this.providers.size(); i1 >= 0; --i1)
        ((PackageParser.Provider)this.providers.get(i1)).setPackageName(paramString);
      for (int i2 = -1 + this.services.size(); i2 >= 0; --i2)
        ((PackageParser.Service)this.services.get(i2)).setPackageName(paramString);
      for (int i3 = -1 + this.instrumentation.size(); i3 >= 0; --i3)
        ((PackageParser.Instrumentation)this.instrumentation.get(i3)).setPackageName(paramString);
    }

    public String toString()
    {
      return "Package{" + Integer.toHexString(System.identityHashCode(this)) + " " + this.packageName + "}";
    }
  }

  public static class PackageLite
  {
    public int installLocation;
    public String mScanPath;
    public String packageName;

    public PackageLite(String paramString, int paramInt)
    {
      this.packageName = paramString;
      this.installLocation = paramInt;
    }
  }

  static class ParseComponentArgs extends PackageParser.ParsePackageItemArgs
  {
    final int descriptionRes;
    final int enabledRes;
    int flags;
    final int processRes;
    final String[] sepProcesses;

    ParseComponentArgs(PackageParser.Package paramPackage, String[] paramArrayOfString1, int paramInt1, int paramInt2, int paramInt3, int paramInt4, String[] paramArrayOfString2, int paramInt5, int paramInt6, int paramInt7)
    {
      super(paramPackage, paramArrayOfString1, paramInt1, paramInt2, paramInt3, paramInt4);
      this.sepProcesses = paramArrayOfString2;
      this.processRes = paramInt5;
      this.descriptionRes = paramInt6;
      this.enabledRes = paramInt7;
    }
  }

  static class ParsePackageItemArgs
  {
    final int iconRes;
    final int labelRes;
    final int logoRes;
    final int nameRes;
    final String[] outError;
    final PackageParser.Package owner;
    TypedArray sa;
    String tag;

    ParsePackageItemArgs(PackageParser.Package paramPackage, String[] paramArrayOfString, int paramInt1, int paramInt2, int paramInt3, int paramInt4)
    {
      this.owner = paramPackage;
      this.outError = paramArrayOfString;
      this.nameRes = paramInt1;
      this.labelRes = paramInt2;
      this.iconRes = paramInt3;
      this.logoRes = paramInt4;
    }
  }

  public static final class Permission extends PackageParser.Component<PackageParser.IntentInfo>
  {
    public PackageParser.PermissionGroup group;
    public final PermissionInfo info;
    public boolean tree;

    public Permission(PackageParser.Package paramPackage)
    {
      super(paramPackage);
      this.info = new PermissionInfo();
    }

    public Permission(PackageParser.Package paramPackage, PermissionInfo paramPermissionInfo)
    {
      super(paramPackage);
      this.info = paramPermissionInfo;
    }

    public void setPackageName(String paramString)
    {
      super.setPackageName(paramString);
      this.info.packageName = paramString;
    }

    public String toString()
    {
      return "Permission{" + Integer.toHexString(System.identityHashCode(this)) + " " + this.info.name + "}";
    }
  }

  public static final class PermissionGroup extends PackageParser.Component<PackageParser.IntentInfo>
  {
    public final PermissionGroupInfo info;

    public PermissionGroup(PackageParser.Package paramPackage)
    {
      super(paramPackage);
      this.info = new PermissionGroupInfo();
    }

    public PermissionGroup(PackageParser.Package paramPackage, PermissionGroupInfo paramPermissionGroupInfo)
    {
      super(paramPackage);
      this.info = paramPermissionGroupInfo;
    }

    public void setPackageName(String paramString)
    {
      super.setPackageName(paramString);
      this.info.packageName = paramString;
    }

    public String toString()
    {
      return "PermissionGroup{" + Integer.toHexString(System.identityHashCode(this)) + " " + this.info.name + "}";
    }
  }

  public static final class Provider extends PackageParser.Component
  {
    public final ProviderInfo info;
    public boolean syncable;

    public Provider(PackageParser.ParseComponentArgs paramParseComponentArgs, ProviderInfo paramProviderInfo)
    {
      super(paramParseComponentArgs, paramProviderInfo);
      this.info = paramProviderInfo;
      this.info.applicationInfo = paramParseComponentArgs.owner.applicationInfo;
      this.syncable = false;
    }

    public Provider(Provider paramProvider)
    {
      super(paramProvider);
      this.info = paramProvider.info;
      this.syncable = paramProvider.syncable;
    }

    public void setPackageName(String paramString)
    {
      super.setPackageName(paramString);
      this.info.packageName = paramString;
    }

    public String toString()
    {
      return "Provider{" + Integer.toHexString(System.identityHashCode(this)) + " " + this.info.name + "}";
    }
  }

  public static final class Service extends PackageParser.Component<PackageParser.ServiceIntentInfo>
  {
    public final ServiceInfo info;

    public Service(PackageParser.ParseComponentArgs paramParseComponentArgs, ServiceInfo paramServiceInfo)
    {
      super(paramParseComponentArgs, paramServiceInfo);
      this.info = paramServiceInfo;
      this.info.applicationInfo = paramParseComponentArgs.owner.applicationInfo;
    }

    public void setPackageName(String paramString)
    {
      super.setPackageName(paramString);
      this.info.packageName = paramString;
    }

    public String toString()
    {
      return "Service{" + Integer.toHexString(System.identityHashCode(this)) + " " + getComponentShortName() + "}";
    }
  }

  public static final class ServiceIntentInfo extends PackageParser.IntentInfo
  {
    public final PackageParser.Service service;

    public ServiceIntentInfo(PackageParser.Service paramService)
    {
      this.service = paramService;
    }

    public String toString()
    {
      return "ServiceIntentInfo{" + Integer.toHexString(System.identityHashCode(this)) + " " + this.service.info.name + "}";
    }
  }
}

/* Location:           H:\360云盘\lewa_explorer_3.0\bin\FileApp_orig_dex2jar.jar
 * Qualified Name:     android.content.pm.PackageParser
 * JD-Core Version:    0.5.2
 */